1.1 --- a/core/sm_stringutil.cpp Fri Jan 12 05:23:39 2007 +0000
1.2 +++ b/core/sm_stringutil.cpp Fri Jan 12 23:56:02 2007 +0000
1.3 @@ -2,20 +2,18 @@
1.4 #include <ctype.h>
1.5 #include <stdarg.h>
1.6 #include "sm_stringutil.h"
1.7 +#include "CLogger.h"
1.8
1.9 #define LADJUST 0x00000004 /* left adjustment */
1.10 #define ZEROPAD 0x00000080 /* zero (as opposed to blank) pad */
1.11 #define to_digit(c) ((c) - '0')
1.12 #define is_digit(c) ((unsigned)to_digit(c) <= 9)
1.13
1.14 -//:TODO: fix this macro when we have a debugger
1.15 -
1.16 -#define CHECK_ARGS(n)/* \
1.17 - if ((arg+n) > args) { \
1.18 - LogError(amx, AMX_ERR_PARAMS, "String formatted incorrectly - parameter %d (total %d)", arg, args); \
1.19 - return 0; \
1.20 +#define CHECK_ARGS(x) \
1.21 + if ((arg+x) > args) { \
1.22 + g_Logger.LogError("String formatted incorrectly - parameter %d (total %d)", arg, args); \
1.23 + return 0; \
1.24 }
1.25 -*/
1.26
1.27 //:TODO: review this code before we choose a license
1.28
1.29 @@ -421,8 +419,7 @@
1.30 }
1.31
1.32 int arg;
1.33 - //int args = params[0] / sizeof(cell); //:TODO: wrong, i think params[0] has now the param count not the byte count
1.34 - // either way this is only used when the above macro is fixed, until then not needed
1.35 + int args = params[0];
1.36 char *buf_p;
1.37 char ch;
1.38 int flags;