Ignore:
Timestamp:
12/24/07 15:43:02 (12 years ago)
Author:
Eoin
Message:

Added small backing up of previous data xml files.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/global/ini.cpp

    r303 r357  
    3434        ini_impl(std::wstring filename) : 
    3535                working_file_(app().working_directory()/filename) 
    36         {} 
     36        { 
     37                boost::filesystem::wpath backup = app().working_directory()/(filename + L".pre"); 
     38                 
     39                if (boost::filesystem::exists(backup)) 
     40                        boost::filesystem::remove(backup); 
     41                         
     42                if (boost::filesystem::exists(working_file_)) 
     43                        boost::filesystem::copy_file(working_file_, backup); 
     44        } 
    3745         
    3846        void load_data() 
Note: See TracChangeset for help on using the changeset viewer.