* iri.c (remote_to_utf8): Fixed assumption that char is signed.

Fixes fellowing test case failures idn-cmd-utf8, idn-robots-utf8,
if char is unsigned.
This commit is contained in:
Jakub Čajka 2014-11-03 14:17:02 +01:00 committed by Tim Rühsen
parent 5e71d5aea1
commit 981c7456ff
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2014-11-03 Jakub Čajka <jcajka@redhat.com>
* iri.c (remote_to_utf8): Fixed assumption that char is signed. Fixes
fellowing test case failures idn-cmd-utf8, idn-robots-utf8, if char is
unsigned.
2014-11-03 Tim Ruehsen <tim.ruehsen@gmx.de>
* log.c: turn on automatic format check for log_vprintf_internal()

View File

@ -279,7 +279,7 @@ remote_to_utf8 (struct iri *iri, const char *str, const char **new)
{
const char *p = str;
for (p = str; *p; p++)
if (*p < 0)
if (*p < 0 || *p > 127)
{
*new = strdup (str);
return true;