summaryrefslogtreecommitdiff
path: root/capplets
diff options
context:
space:
mode:
authorValentin Villenave <[email protected]>2021-10-22 10:43:53 +0200
committerraveit65 <[email protected]>2023-05-07 17:10:08 +0200
commitb90fe28e2c04043a819384ca408c6963f227381a (patch)
tree6c48b67a7e7a16cfb17bd47ed5cbf6ff2b9f447d /capplets
parent5431e81a503e9bb744771be6eab2d235e9445fd6 (diff)
downloadmate-control-center-b90fe28e2c04043a819384ca408c6963f227381a.tar.bz2
mate-control-center-b90fe28e2c04043a819384ca408c6963f227381a.tar.xz
g_queue_clear_full() is only available since glib 2.60.
Diffstat (limited to 'capplets')
-rw-r--r--capplets/about-me/mate-about-me-password.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/capplets/about-me/mate-about-me-password.c b/capplets/about-me/mate-about-me-password.c
index fd7eb2d9..d03655a4 100644
--- a/capplets/about-me/mate-about-me-password.c
+++ b/capplets/about-me/mate-about-me-password.c
@@ -607,7 +607,13 @@ io_watch_stdout (GIOChannel *source, GIOCondition condition, PasswordDialog *pdi
}
pdialog->backend_state = PASSWD_STATE_ERR;
/* Clean backen_stdin_queue if error occured */
- g_queue_clear_full(pdialog->backend_stdin_queue, g_free);
+#if GLIB_CHECK_VERSION(2, 60, 0)
+ g_queue_clear_full (pdialog->backend_stdin_queue, g_free);
+#else
+ /* TODO: Remove this if/when GLib compatibility gets dropped. */
+ g_queue_foreach (pdialog->backend_stdin_queue, (GFunc) g_free, NULL);
+ g_queue_clear (pdialog->backend_stdin_queue);
+#endif
g_free (msg);
}
break;