This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: strxfrm() returns an incorrect value on a short buffer


On Apr 12 15:07, Tony Cook wrote:
> strxfrm() returns an incorrect value if you supply an output buffer
> and that buffer is too short for the result.
> 
> With the code following:
> [...]
> It appears that strxfrm() is just returning the size of the output
> buffer on an overflow error rather than calling LCMapString() again
> with cchDest set to zero to get the required buffer length that
> strxfrm() is meant to return on a short buffer.

Thanks for the testcase.  I applied a patch

  https://sourceware.org/git/?p=newlib-cygwin.git;h=e1854211

and created new snapshots on

  https://cygwin.com/snapshots/

Please give them a try.


Thanks,
Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

Attachment: signature.asc
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]