gnome-volume-manager r1416 - in trunk: . src



Author: fejj
Date: Sun Feb 15 20:22:13 2009
New Revision: 1416
URL: http://svn.gnome.org/viewvc/gnome-volume-manager?rev=1416&view=rev

Log:
2009-02-15  Jeffrey Stedfast  <fejj novell com>

	* src/manager.c (gvm_console_kit_sesion_get_uid): ConsoleKit 0.3
	changed the return value from Int32 to UInt32 so check for either
	type. Based on a patch by Donnie Berkholz.



Modified:
   trunk/ChangeLog
   trunk/src/manager.c

Modified: trunk/src/manager.c
==============================================================================
--- trunk/src/manager.c	(original)
+++ trunk/src/manager.c	Sun Feb 15 20:22:13 2009
@@ -3947,7 +3947,9 @@
 	dbus_message_unref (dmesg);
 	
 	dbus_message_iter_init (reply, &iter);
-	if (dbus_message_iter_get_arg_type (&iter) != DBUS_TYPE_INT32) {
+	/* ConsoleKit < 0.3 return Int32 whereas >= 0.3 return UInt32 */
+	if (dbus_message_iter_get_arg_type (&iter) != DBUS_TYPE_INT32 &&
+	    dbus_message_iter_get_arg_type (&iter) != DBUS_TYPE_UINT32) {
 		dbg ("Unrecognized response to ConsoleKit GetUnixUser request\n");
 		dbus_message_unref (reply);
 		return FALSE;



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