View Single Post
  #7   Spotlight this post!  
Unread 17-01-2005, 12:50
the_undefined's Avatar
the_undefined the_undefined is offline
German FES
AKA: Felix Geisendörfer
#1648 (Gearbox Gangstas)
Team Role: Programmer
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Germany
Posts: 77
the_undefined has a spectacular aura aboutthe_undefined has a spectacular aura about
Re: Help: Misterious 8292 Bug

Quote:
Originally Posted by Mark McLeod
Per printf call.
You can break up that printf of yours into two printf's and it will work fine.

The print_lib.c file has this lurking warning as part of the lead comment block:
Code:
* 3. The %s directive only supports a string of 40 bytes and the format string
* may not exceed 80 bytes. The sprintf routine is not included. Keep in 
* mind that the stack size has a 256 byte limit.

That's the safest idea, to modify the IFI printf code to add a check for strings > the limit. We simply truncate the string if it's longer than ifi_printfBufr.
Ok thx again for this additional information. As I said I was completly unaware that printf can get me into such trouble so I didn't pay enough attention to the comments in the class. For the next "misterious bug" I'll read the comments in the included classes/functions first ... : )

Bye

Felix