changeset 2418:1b109bc34ede trunk

[svn] - fix: W:playlist_list.c(162) [get_transparency_pixmap]: possible type-punned pointer dereference
author nenolod
date Fri, 26 Jan 2007 18:10:18 -0800
parents ea17b8ee57d8
children 884a00d035d2
files ChangeLog src/audacious/widgets/playlist_list.c
diffstat 2 files changed, 14 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Fri Jan 26 14:55:25 2007 -0800
+++ b/ChangeLog	Fri Jan 26 18:10:18 2007 -0800
@@ -1,3 +1,11 @@
+2007-01-26 22:55:25 +0000  Michael Farber <01mf02@gmail.com>
+  revision [3844]
+  oops, forgot to add the fileopener files
+  trunk/src/audacious/ui_fileopener.c |  440 ++++++++++++++++++++++++++++++++++++
+  trunk/src/audacious/ui_fileopener.h |   28 ++
+  2 files changed, 468 insertions(+)
+
+
 2007-01-26 22:50:30 +0000  Michael Farber <01mf02@gmail.com>
   revision [3842]
   integrated urldecode.* from libaudacious into audacious directory, made separate ui_fileopener.*
--- a/src/audacious/widgets/playlist_list.c	Fri Jan 26 14:55:25 2007 -0800
+++ b/src/audacious/widgets/playlist_list.c	Fri Jan 26 18:10:18 2007 -0800
@@ -142,11 +142,12 @@
 GdkDrawable *get_transparency_pixmap(void)
 {
 	GdkDrawable *root;
-	XID *pixmaps;
+	guchar *pm = NULL;
 	GdkAtom prop_type;
 	gint prop_size;
 	GdkPixmap *pixmap;
 	gboolean ret;
+	XID *pixmaps;
 
 	root = gdk_get_default_root_window();
 
@@ -159,10 +160,13 @@
 			0, 0, INT_MAX - 3,
 			FALSE,
 			&prop_type, NULL, &prop_size,
-			(guchar **) &pixmaps);
+			&pm);
 
 	gdk_error_trap_pop();
 
+	if (pm != NULL)
+		pixmaps = (XID *) pm;
+
 	if ((ret == TRUE) && (prop_type == GDK_TARGET_PIXMAP) && (prop_size >= sizeof(XID)) && (pixmaps != NULL))
 	{
 		pixmap = gdk_pixmap_foreign_new_for_display(gdk_drawable_get_display(root),