Fix a warning (again)
authorDan Winship <danw@gnome.org>
Tue, 25 Jan 2011 17:18:57 +0000 (12:18 -0500)
committerDan Winship <danw@gnome.org>
Tue, 25 Jan 2011 17:18:57 +0000 (12:18 -0500)
soup-date uses strtoul() to parse the sub-second portion of an ISO
8601 timestamp (to verify that it's syntactically valid), but then
throws that information away. gcc 4.6 is pickier about how we throw it
away though.

libsoup/soup-date.c

index 25bb761..99ba2f0 100644 (file)
@@ -211,7 +211,7 @@ soup_date_new_from_now (int offset_seconds)
 static gboolean
 parse_iso8601_date (SoupDate *date, const char *date_string)
 {
-       gulong val, ignored;
+       gulong val;
 
        if (strlen (date_string) < 15)
                return FALSE;
@@ -250,7 +250,7 @@ parse_iso8601_date (SoupDate *date, const char *date_string)
                return FALSE;
 
        if (*date_string == '.' || *date_string == ',')
-               ignored = strtoul (date_string + 1, (char **)&date_string, 10);
+               (void) strtoul (date_string + 1, (char **)&date_string, 10);
 
        if (*date_string == 'Z') {
                date_string++;