[Scummvm-cvs-logs] CVS: scummvm/gob debug.cpp,1.3,1.4
Jonathan Gray
khalek at users.sourceforge.net
Fri Apr 8 18:53:12 CEST 2005
Update of /cvsroot/scummvm/scummvm/gob
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26313/gob
Modified Files:
debug.cpp
Log Message:
Remove usage of vsprintf in favour of vsnprintf and make
more use of STRINGBUFLEN. Some ports may need a new stub for
this, discussed with Chrilith.
Index: debug.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/gob/debug.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- debug.cpp 5 Apr 2005 16:25:51 -0000 1.3
+++ debug.cpp 9 Apr 2005 01:52:42 -0000 1.4
@@ -26,7 +26,7 @@
namespace Gob {
static int16 logFile = -2;
-static char buf[256];
+static char buf[STRINGBUFLEN];
extern uint32 always0_dword_23EC_560;
@@ -50,7 +50,7 @@
log_init();
if (logFile >= 0) {
- vsprintf(buf, format, lst);
+ vsnprintf(buf, STRINGBUFLEN, format, lst);
write(logFile, buf, strlen(buf));
}
More information about the Scummvm-git-logs
mailing list