mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-10-07 06:00:06 +02:00
Don't leave out parameters uninitialized. (#490061, Benjamin Otte)
2007-11-08 Matthias Clasen <mclasen@redhat.com> * glib/gstrfuncs.c (g_parse_long_long): Don't leave out parameters uninitialized. (#490061, Benjamin Otte) svn path=/branches/glib-2-14/; revision=5824
This commit is contained in:
committed by
Matthias Clasen
parent
a9c034f68d
commit
2afc38c88f
@@ -1,3 +1,8 @@
|
||||
2007-11-08 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* glib/gstrfuncs.c (g_parse_long_long): Don't leave
|
||||
out parameters uninitialized. (#490061, Benjamin Otte)
|
||||
|
||||
2007-11-07 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
=== Branch for 2.14 ===
|
||||
|
@@ -650,9 +650,12 @@ g_parse_long_long (const gchar *nptr,
|
||||
|
||||
g_return_val_if_fail (nptr != NULL, 0);
|
||||
|
||||
*negative = FALSE;
|
||||
if (base == 1 || base > 36)
|
||||
{
|
||||
errno = EINVAL;
|
||||
if (endptr)
|
||||
*endptr = nptr;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -666,7 +669,6 @@ g_parse_long_long (const gchar *nptr,
|
||||
goto noconv;
|
||||
|
||||
/* Check for a sign. */
|
||||
*negative = FALSE;
|
||||
if (*s == '-')
|
||||
{
|
||||
*negative = TRUE;
|
||||
|
Reference in New Issue
Block a user