From: Tony Cook <tony@develop-help.com>
To: cygwin@cygwin.com
Subject: Re: strxfrm() returns an incorrect value on a short buffer
Date: Wed, 13 Apr 2016 00:46:00 -0000 [thread overview]
Message-ID: <20160413004628.GH12445@mars.tony.develop-help.com> (raw)
In-Reply-To: <20160412133049.GN9870@calimero.vinschen.de>
On Tue, Apr 12, 2016 at 03:30:49PM +0200, Corinna Vinschen wrote:
> 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, fixed in snapshot 20160412.
Tony
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
next prev parent reply other threads:[~2016-04-13 0:46 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-12 5:07 Tony Cook
2016-04-12 8:35 ` Marco Atzeri
2016-04-12 10:20 ` Achim Gratz
2016-04-12 10:57 ` Tony Cook
2016-04-12 13:31 ` Corinna Vinschen
2016-04-13 0:46 ` Tony Cook [this message]
2016-04-13 8:10 ` Corinna Vinschen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160413004628.GH12445@mars.tony.develop-help.com \
--to=tony@develop-help.com \
--cc=cygwin@cygwin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).