[retro-gtk] pixdata: Directly use g_free() as the data destructor
- From: Adrien Plazas <aplazas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [retro-gtk] pixdata: Directly use g_free() as the data destructor
- Date: Mon, 21 Dec 2020 15:39:29 +0000 (UTC)
commit 021d6270455ca57370bf635ab2d1a2d15510c54c
Author: Adrien Plazas <kekun plazas laposte net>
Date: Mon Dec 21 15:54:28 2020 +0100
pixdata: Directly use g_free() as the data destructor
No need to wrap it here.
retro-gtk/retro-pixdata.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)
---
diff --git a/retro-gtk/retro-pixdata.c b/retro-gtk/retro-pixdata.c
index fa40efd..7787465 100644
--- a/retro-gtk/retro-pixdata.c
+++ b/retro-gtk/retro-pixdata.c
@@ -151,13 +151,6 @@ rgba8888_from_video (gconstpointer src,
}
}
-static void
-pixels_free (guchar *pixels,
- gpointer data)
-{
- g_free (pixels);
-}
-
/**
* retro_pixdata_new:
* @data: the video data
@@ -360,7 +353,7 @@ retro_pixdata_to_pixbuf (RetroPixdata *self)
GDK_COLORSPACE_RGB, TRUE, 8,
self->width, self->height,
self->width * sizeof (rgba8888),
- pixels_free, NULL);
+ (GdkPixbufDestroyNotify) g_free, NULL);
/* x-dpi and y-dpi are deprecated, retro_pixbuf_get_aspect_ratio() and
* retro_pixbuf_set_aspect_ratio() should be used instead. */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]