gnome-media r4186 - in trunk/gnome-volume-control: . src



Author: hadess
Date: Thu Feb 12 11:01:29 2009
New Revision: 4186
URL: http://svn.gnome.org/viewvc/gnome-media?rev=4186&view=rev

Log:
2009-02-12  Bastien Nocera  <hadess hadess net>

	* src/gvc-mixer-control.c (gvc_stream_collate): Fix run-time
	warning when there's no name for a stream, such as some events
	from libcanberra



Modified:
   trunk/gnome-volume-control/ChangeLog
   trunk/gnome-volume-control/src/gvc-mixer-control.c

Modified: trunk/gnome-volume-control/src/gvc-mixer-control.c
==============================================================================
--- trunk/gnome-volume-control/src/gvc-mixer-control.c	(original)
+++ trunk/gnome-volume-control/src/gvc-mixer-control.c	Thu Feb 12 11:01:29 2009
@@ -220,6 +220,13 @@
         namea = gvc_mixer_stream_get_name (a);
         nameb = gvc_mixer_stream_get_name (b);
 
+        if (nameb == NULL && namea == NULL)
+        	return 0;
+        if (nameb == NULL)
+        	return 1;
+        if (namea == NULL)
+        	return -1;
+
         return g_utf8_collate (namea, nameb);
 }
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]