[totem-pl-parser/wip/hadess/warning-fixes: 2/2] podcast: Fix deprecation warnings
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [totem-pl-parser/wip/hadess/warning-fixes: 2/2] podcast: Fix deprecation warnings
- Date: Fri, 11 Feb 2022 09:36:33 +0000 (UTC)
commit c6c1c51aefeac28499da9fe5cec4af2278ed1564
Author: Bastien Nocera <hadess hadess net>
Date: Fri Feb 11 10:35:50 2022 +0100
podcast: Fix deprecation warnings
../../../../Projects/jhbuild/totem-pl-parser/plparse/totem-pl-parser-decode-date.c: In function
‘get_tzone’:
../../../../Projects/jhbuild/totem-pl-parser/plparse/totem-pl-parser-decode-date.c:322:25: warning:
‘g_time_zone_new’ is deprecated: Use 'g_time_zone_new_identifier' instead [-Wdeprecated-declarations]
322 | return g_time_zone_new (tzone);
| ^~~~~~
In file included from /usr/include/glib-2.0/glib/gdatetime.h:31,
from /usr/include/glib-2.0/glib/gbookmarkfile.h:26,
from /usr/include/glib-2.0/glib.h:37,
from
../../../../Projects/jhbuild/totem-pl-parser/plparse/totem-pl-parser-decode-date.h:20,
from
../../../../Projects/jhbuild/totem-pl-parser/plparse/totem-pl-parser-decode-date.c:24:
/usr/include/glib-2.0/glib/gtimezone.h:57:25: note: declared here
57 | GTimeZone * g_time_zone_new (const gchar *identifier);
| ^~~~~~~~~~~~~~~
../../../../Projects/jhbuild/totem-pl-parser/plparse/totem-pl-parser-decode-date.c:341:25: warning:
‘g_time_zone_new’ is deprecated: Use 'g_time_zone_new_identifier' instead [-Wdeprecated-declarations]
341 | return g_time_zone_new (tzone);
| ^~~~~~
In file included from /usr/include/glib-2.0/glib/gdatetime.h:31,
from /usr/include/glib-2.0/glib/gbookmarkfile.h:26,
from /usr/include/glib-2.0/glib.h:37,
from
../../../../Projects/jhbuild/totem-pl-parser/plparse/totem-pl-parser-decode-date.h:20,
from
../../../../Projects/jhbuild/totem-pl-parser/plparse/totem-pl-parser-decode-date.c:24:
/usr/include/glib-2.0/glib/gtimezone.h:57:25: note: declared here
57 | GTimeZone * g_time_zone_new (const gchar *identifier);
| ^~~~~~~~~~~~~~~
plparse/totem-pl-parser-decode-date.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/plparse/totem-pl-parser-decode-date.c b/plparse/totem-pl-parser-decode-date.c
index 0111ffb..3441e59 100644
--- a/plparse/totem-pl-parser-decode-date.c
+++ b/plparse/totem-pl-parser-decode-date.c
@@ -319,7 +319,7 @@ get_tzone (date_token **token)
memcpy (tzone, inptr, len);
tzone[len] = '\0';
- return g_time_zone_new (tzone);
+ return g_time_zone_new_identifier (tzone);
}
if (*inptr == '(') {
@@ -338,7 +338,7 @@ get_tzone (date_token **token)
snprintf (tzone, 6, "%+05d", tz_offsets[t].offset);
- return g_time_zone_new (tzone);
+ return g_time_zone_new_identifier (tzone);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]