diff --git a/src/modules/sni/item.cpp b/src/modules/sni/item.cpp index 991ccc4d..d9748eda 100644 --- a/src/modules/sni/item.cpp +++ b/src/modules/sni/item.cpp @@ -287,7 +287,11 @@ Glib::RefPtr Item::extractPixBuf(GVariant* variant) { if (array != nullptr) { g_free(array); } +#if GLIB_MAJOR_VERSION >= 2 && GLIB_MINOR_VERSION >= 68 + array = static_cast(g_memdup2(data, size)); +#else array = static_cast(g_memdup(data, size)); +#endif lwidth = width; lheight = height; }