[SYSTEM-WIN95] borland, sprintf, autoexit

From: Kingmundi (Kingmundi@AOL.COM)
Date: 12/13/97


yeah, there is something odd in the way borland c++ handles sprintf,
it has something to do with the fact the autoexit function uses two buf
char arrays in the same sprintf statement, like follows,

sprintf(buf, "%s%c ", buf, LOWER(*dirs[door]));

i wrote the following to test the idea within the autoexits for loop,

char command[254];
sprintf(buf, "%s%c ", command, LOWER(*dirs[door]));
strcpy(command, buf);

it lists all the exits, except somewhere it is assigning something wrong
for in each exit list, the first two characters are garbage

a U with two dots over it, followed by a solid black square,
north, east, south, west


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST