Fixed some bugs in CLang

This commit is contained in:
David Anderson 2004-09-02 00:22:56 +00:00
parent 7a627f75cf
commit 5c6b34b1d8

View File

@ -611,8 +611,6 @@ char * CLangMngr::FormatAmxString(AMX *amx, cell *params, int parm, int &len)
while (tmpPtr-tmpString < sizeof(tmpString) && *tmpCell) while (tmpPtr-tmpString < sizeof(tmpString) && *tmpCell)
*tmpPtr++ = *tmpCell++; *tmpPtr++ = *tmpCell++;
ZEROTERM(tmpString);
*tmpPtr = 0; *tmpPtr = 0;
sprintf(outptr, format, tmpString); sprintf(outptr, format, tmpString);
ZEROTERM(outbuf); ZEROTERM(outbuf);
@ -687,9 +685,9 @@ char * CLangMngr::FormatAmxString(AMX *amx, cell *params, int parm, int &len)
{ {
while (*src != 0 && ptr-format<sizeof(format) && !isalpha(*ptr++ = *src++)) while (*src != 0 && ptr-format<sizeof(format) && !isalpha(*ptr++ = *src++))
/*nothing*/; /*nothing*/;
*ptr = 0;
ZEROTERM(format); ZEROTERM(format);
--src; --src;
*ptr = 0;
switch ( *(ptr-1) ) switch ( *(ptr-1) )
{ {
case 's': case 's':