making scanf byte-clean(er)
Sun Jan 10 21:28:00 GMT 2010
On Jan 10 19:39, Andy Koppe wrote:
> Attached is a patch for making the scanf format string (more)
> byte-transparent. It actually couldn't deal with non-ASCII chars at
> all, even valid ones, due to comparing an 'unsigned char' with a
> (signed) 'char'. And when encountering an invalid byte, it would go
> backwards in the format string. Finally, it wrongly reset the
> multibyte conversion state for every character and used the same state
> object for the format string and %ls arguments.
> I thought I'd send the patch here for review first before sending it
> upstream. Hope that makes sense.
Well... we're all reading newlib anyway and the code you're changing is
affecting all newlib targets, not just Cygwin. If you remove the
vfprintf patch and add the missing ChangeLog entry before sending it to
the newlib list, we might better discuss it right there.
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
More information about the Cygwin-patches