libmm-glib,common-helpers: undeprecate g_date_time_format_iso8601()
Avoid a deprecation warning with too new glib: ../libmm-glib/mm-common-helpers.c: In function ‘date_time_format_iso8601’: ../libmm-glib/mm-common-helpers.c:1729:5: warning: ‘g_date_time_format_iso8601’ is deprecated: Not available before 2.62 [-Wdeprecated-declarations] 1729 | return g_date_time_format_iso8601 (dt); | ^~~~~~ This call site is protected by version guards and provides an alternative implementation in date_time_format_iso8601().
This commit is contained in:

committed by
Aleksander Morgado

parent
6179667d3d
commit
1af34e1746
@@ -1726,7 +1726,9 @@ static gchar *
|
|||||||
date_time_format_iso8601 (GDateTime *dt)
|
date_time_format_iso8601 (GDateTime *dt)
|
||||||
{
|
{
|
||||||
#if GLIB_CHECK_VERSION (2, 62, 0)
|
#if GLIB_CHECK_VERSION (2, 62, 0)
|
||||||
|
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
||||||
return g_date_time_format_iso8601 (dt);
|
return g_date_time_format_iso8601 (dt);
|
||||||
|
G_GNUC_END_IGNORE_DEPRECATIONS
|
||||||
#else
|
#else
|
||||||
GString *outstr = NULL;
|
GString *outstr = NULL;
|
||||||
g_autofree gchar *main_date = NULL;
|
g_autofree gchar *main_date = NULL;
|
||||||
|
Reference in New Issue
Block a user