mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-10 11:26:16 +01:00
Merge branch 'ossfuzz-17648-date-uninit-variable' into 'master'
gdatetime: Fix error handling in g_date_time_new_week() See merge request GNOME/glib!1125
This commit is contained in:
commit
03e3a0396e
@ -1241,6 +1241,8 @@ g_date_time_new_week (GTimeZone *tz, gint year, gint week, gint week_day, gint h
|
||||
return NULL;
|
||||
|
||||
dt = g_date_time_new (tz, year, 1, 4, 0, 0, 0);
|
||||
if (dt == NULL)
|
||||
return NULL;
|
||||
g_date_time_get_week_number (dt, NULL, &jan4_week_day, NULL);
|
||||
g_date_time_unref (dt);
|
||||
|
||||
|
@ -868,6 +868,7 @@ test_GDateTime_new_from_iso8601_2 (void)
|
||||
*/
|
||||
{ FALSE, "1719W462 407777-07", 0, 0, 0, 0, 0, 0, 0, 0 },
|
||||
{ FALSE, "4011090 260528Z", 0, 0, 0, 0, 0, 0, 0, 0 },
|
||||
{ FALSE, "0000W011 228214-22", 0, 0, 0, 0, 0, 0, 0, 0 },
|
||||
};
|
||||
GTimeZone *tz = NULL;
|
||||
GDateTime *dt = NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user