snprintf() in rtems

Smith, Gene Gene.Smith at
Mon Feb 4 19:50:24 UTC 2002

Should this code fragment work?

char	sendstr[21];
float pi = 3.1415;

snprintf(sendstr, sizeof sendstr -1, "%f", pi);

It seems like snprintf never returns and the system hangs.
I am able to use snprintf with interger formats with no problem.
The code actually does no actual math operations, except for this 
type of formatting.

bsp is approx. 386ex with no math or fp library that I know of.

Tried printf and it does the same thing. 

I can see f*** (floating point) opcodes in code, e.g., _vf_printf_r from

Anybody know?


More information about the users mailing list