zamotivator

Untitled

Feb 3rd, 2012
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. void save_index::write_save_index()
  2. {
  3. log_scope("write_save_index()");
  4. try {
  5. scoped_ostream stream = ostream_file(get_save_index_file());
  6. if (preferences::compress_saves()) {
  7. write_gz(*stream, load());
  8. } else {
  9. write(*stream, load());
  10. }
  11. } catch(io_exception& e) {
  12. ERR_SAVE << "error writing to save index file: '" << e.what() << "'\n";
  13. }
  14. }
Advertisement
Add Comment
Please, Sign In to add comment