aboutsummaryrefslogtreecommitdiffstats
path: root/src/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/util.c')
-rw-r--r--src/util.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/util.c b/src/util.c
index 2efd8f0d5..dea3976f1 100644
--- a/src/util.c
+++ b/src/util.c
@@ -1124,6 +1124,17 @@ g_ptr_array_unref (GPtrArray *array)
g_ptr_array_free (array, TRUE);
}
#endif
+#if ((GLIB_MAJOR_VERSION == 2) && (GLIB_MINOR_VERSION < 14))
+void
+g_queue_clear (GQueue *queue)
+{
+ g_return_if_fail (queue != NULL);
+
+ g_list_free (queue->head);
+ queue->head = queue->tail = NULL;
+ queue->length = 0;
+}
+#endif
gsize
rspamd_strlcpy (gchar *dst, const gchar *src, gsize siz)