Update of bug #22800 (project avr-libc):
Assigned to: None => dmix
_______________________________________________________
Follow-up Comment #1:
Dmitry, can you check this, please?
I think this is a bug somewhere in the following snippet:
case 's':
pnt = va_arg (ap, char *);
size = strnlen (pnt, (flags & FL_PREC) ? prec : ~0);
no_pgmstring:
flags &= ~FL_PGMSTRING;
goto str_lpad;
case 'S':
pnt = va_arg (ap, char *);
size = strnlen_P (pnt, (flags & FL_PREC) ? prec : ~0);
flags |= FL_PGMSTRING;
str_lpad:
if (!(flags & FL_LPAD)) {
while (size < width) {
putc (' ', stream);
width--;
}
}
while (size) {
putc (GETBYTE (flags, FL_PGMSTRING, pnt), stream);
if (width) width -= 1;
size -= 1;
}
My guess is that width has to be declared as uint16_t rather
than unsigned char. What do you think?
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/bugs/?22800>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
_______________________________________________
AVR-libc-dev mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/avr-libc-dev