comparison src/saveload/saveload.cpp @ 11875:86fca539ec7a draft

(svn r16269) -Codechange: use gcc's ability to check parameters sent to printf-like functions -Fix: wrong number of parameters or wrong parameter types sent to printf-like functions at several places
author smatz <smatz@openttd.org>
date Sun, 10 May 2009 17:27:25 +0000
parents 862dd1024fe7
children 0a4b63f3f3c3
comparison
equal deleted inserted replaced
11874:1091625b3d21 11875:86fca539ec7a
1638 catch (...) { 1638 catch (...) {
1639 AbortSaveLoad(); 1639 AbortSaveLoad();
1640 if (_sl.excpt_uninit != NULL) _sl.excpt_uninit(); 1640 if (_sl.excpt_uninit != NULL) _sl.excpt_uninit();
1641 1641
1642 /* Skip the "colour" character */ 1642 /* Skip the "colour" character */
1643 DEBUG(sl, 0, GetSaveLoadErrorString() + 3); 1643 DEBUG(sl, 0, "%s", GetSaveLoadErrorString() + 3);
1644 1644
1645 if (threaded) { 1645 if (threaded) {
1646 SetAsyncSaveFinish(SaveFileError); 1646 SetAsyncSaveFinish(SaveFileError);
1647 } else { 1647 } else {
1648 SaveFileError(); 1648 SaveFileError();
1838 1838
1839 /* deinitialize compressor. */ 1839 /* deinitialize compressor. */
1840 if (_sl.excpt_uninit != NULL) _sl.excpt_uninit(); 1840 if (_sl.excpt_uninit != NULL) _sl.excpt_uninit();
1841 1841
1842 /* Skip the "colour" character */ 1842 /* Skip the "colour" character */
1843 DEBUG(sl, 0, GetSaveLoadErrorString() + 3); 1843 DEBUG(sl, 0, "%s", GetSaveLoadErrorString() + 3);
1844 1844
1845 /* A saver/loader exception!! reinitialize all variables to prevent crash! */ 1845 /* A saver/loader exception!! reinitialize all variables to prevent crash! */
1846 return (mode == SL_LOAD) ? SL_REINIT : SL_ERROR; 1846 return (mode == SL_LOAD) ? SL_REINIT : SL_ERROR;
1847 } 1847 }
1848 } 1848 }