[Scummvm-cvs-logs] CVS: scummvm/scumm debugger.cpp,1.145,1.146 scumm.cpp,1.458,1.459

Max Horn fingolfin at users.sourceforge.net
Sat Apr 23 06:53:09 CEST 2005


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6576/scumm

Modified Files:
	debugger.cpp scumm.cpp 
Log Message:
Simplified debuglevel handling:
 - it's only honored in the global level of the config file
 - all checks for it go through gDebugLevel now, which is made global
 - the '-d' switch is handled in a slightly saner and consistent way
 - removed 'debuglevel' from the config format documentation; we do
   not want to encourage the avarage user to use it


Index: debugger.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/debugger.cpp,v
retrieving revision 1.145
retrieving revision 1.146
diff -u -d -r1.145 -r1.146
--- debugger.cpp	22 Apr 2005 20:04:25 -0000	1.145
+++ debugger.cpp	23 Apr 2005 13:52:27 -0000	1.146
@@ -37,8 +37,6 @@
 
 #include "common/debugger.cpp"
 
-extern int gDebugLevel;
-
 namespace Scumm {
 
 void CDECL debugC(int channel, const char *s, ...) {
@@ -595,7 +593,7 @@
 		if (_vm->_debugMode == false)
 			DebugPrintf("Debugging is not enabled at this time\n");
 		else
-			DebugPrintf("Debugging is currently set at level %d\n", ConfMan.getInt("debuglevel"));
+			DebugPrintf("Debugging is currently set at level %d\n", gDebugLevel);
 	} else { // set level
 		gDebugLevel = atoi(argv[1]);
 		if (gDebugLevel > 0) {

Index: scumm.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scumm.cpp,v
retrieving revision 1.458
retrieving revision 1.459
diff -u -d -r1.458 -r1.459
--- scumm.cpp	22 Apr 2005 00:03:24 -0000	1.458
+++ scumm.cpp	23 Apr 2005 13:52:27 -0000	1.459
@@ -1058,7 +1058,7 @@
 	g_scumm = this;
 
 	// Read settings from the detector & config manager
-	_debugMode = ConfMan.hasKey("debuglevel");
+	_debugMode = (gDebugLevel > 0);
 	_dumpScripts = detector->_dumpScripts;
 	_bootParam = ConfMan.getInt("boot_param");
 





More information about the Scummvm-git-logs mailing list