[Scummvm-cvs-logs] CVS: scummvm/common gameDetector.cpp,1.150,1.151
Travis Howell
kirben at users.sourceforge.net
Fri Sep 5 21:08:02 CEST 2003
Update of /cvsroot/scummvm/scummvm/common
In directory sc8-pr-cvs1:/tmp/cvs-serv2220/common
Modified Files:
gameDetector.cpp
Log Message:
Fix debug level, only > 1 should be valid.
Index: gameDetector.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/common/gameDetector.cpp,v
retrieving revision 1.150
retrieving revision 1.151
diff -u -d -r1.150 -r1.151
--- gameDetector.cpp 6 Sep 2003 03:56:41 -0000 1.150
+++ gameDetector.cpp 6 Sep 2003 04:07:20 -0000 1.151
@@ -333,7 +333,7 @@
_sfx_volume = g_config->getInt("sfx_volume", _sfx_volume);
_debugLevel = g_config->getInt("debuglevel", _debugLevel);
- if (_debugLevel > 0)
+ if (_debugLevel)
_debugMode = true;
// We use strtol for the tempo to allow it to be specified in hex.
@@ -392,11 +392,13 @@
g_config->setInt("cdrom", _cdrom);
break;
case 'd':
- _debugMode = true;
HANDLE_OPT_OPTION();
if (option != NULL)
_debugLevel = atoi(option);
- debug(1,"Debuglevel (from command line): %d", _debugLevel);
+ if (_debugLevel) {
+ _debugMode = true;
+ printf("Debuglevel (from command line): %d\n", _debugLevel);
+ }
break;
case 'e':
HANDLE_OPTION();
@@ -595,7 +597,8 @@
g_config->delete_domain("_COMMAND_LINE");
g_config->delete_domain("_USER_OVERRIDES");
g_config->set_domain(name);
- debug(1, "Debuglevel (from config): %d", _debugLevel);
+ if (_debugMode)
+ printf("Debuglevel (from config): %d\n", _debugLevel);
}
int GameDetector::parseGraphicsMode(const char *s) {
More information about the Scummvm-git-logs
mailing list