Use g_memdup2 instead of g_memdup

This fixes a compile warning.

See: https://discourse.gnome.org/t/port-your-module-from-g-memdup-to-g-memdup2-now/5538
This commit is contained in:
Michael Swiger 2021-08-22 14:46:40 -07:00
parent ab38f13052
commit cb49650ea4

View File

@ -287,7 +287,7 @@ Glib::RefPtr<Gdk::Pixbuf> Item::extractPixBuf(GVariant* variant) {
if (array != nullptr) {
g_free(array);
}
array = static_cast<guchar*>(g_memdup(data, size));
array = static_cast<guchar*>(g_memdup2(data, size));
lwidth = width;
lheight = height;
}