libgnomecups r237 - in trunk: . libgnomecups



Author: kmaraas
Date: Wed Jan 30 17:30:43 2008
New Revision: 237
URL: http://svn.gnome.org/viewvc/libgnomecups?rev=237&view=rev

Log:
2008-01-30  Kjartan Maraas  <kmaraas gnome org>

	* libgnomecups/gnome-cups-printer.c: (set_timeout),
	(gnome_cups_printer_get_state_name),
	(_gnome_cups_printer_get_host): Fix some warnings.
	* libgnomecups/gnome-cups-queue.c: (gnome_cups_queue_get_job):
	Fix wrong order of arguments to g_list_find_custom.

Modified:
   trunk/ChangeLog
   trunk/libgnomecups/gnome-cups-printer.c
   trunk/libgnomecups/gnome-cups-queue.c

Modified: trunk/libgnomecups/gnome-cups-printer.c
==============================================================================
--- trunk/libgnomecups/gnome-cups-printer.c	(original)
+++ trunk/libgnomecups/gnome-cups-printer.c	Wed Jan 30 17:30:43 2008
@@ -791,7 +791,7 @@
 
 	if (should_timeout && !update_timeout_id) {
 		update_timeout_id = g_timeout_add (UPDATE_TIMEOUT, 
-						   update_printers_timeout,
+						   (GSourceFunc)update_printers_timeout,
 						   NULL);
 	} else if (!should_timeout && update_timeout_id) {
 		g_source_remove (update_timeout_id);
@@ -1069,7 +1069,6 @@
 const char *
 gnome_cups_printer_get_state_name (GnomeCupsPrinter *printer)
 {
-	const char *state_str;
 	ipp_pstate_t state;
 
 	g_return_val_if_fail (GNOME_CUPS_IS_PRINTER (printer), NULL);
@@ -1079,7 +1078,7 @@
 
 	state = printer->details->state;
 
-	return state_str =  _(printer_state_strings[state - IPP_PRINTER_IDLE]);
+	return _(printer_state_strings[state - IPP_PRINTER_IDLE]);
 }
 
 const char *
@@ -2001,7 +2000,7 @@
 {
 	gchar *host = NULL;
 
-#warning this is broken for smb://user:pass host/printer urls
+	/* warning this is broken for smb://user:pass host/printer urls */
 	if (go_directly_to_printer_when_possible &&
 	    printer->details->printer_uri) {
 		gchar *x, *y;

Modified: trunk/libgnomecups/gnome-cups-queue.c
==============================================================================
--- trunk/libgnomecups/gnome-cups-queue.c	(original)
+++ trunk/libgnomecups/gnome-cups-queue.c	Wed Jan 30 17:30:43 2008
@@ -413,8 +413,8 @@
 {
 	if (cache_ok) {
 		GList *link = g_list_find_custom (queue->details->jobs,
-						  (GCompareFunc) find_job_by_id,
-						  GINT_TO_POINTER (job_id));
+						  GINT_TO_POINTER (job_id),
+						  (GCompareFunc) find_job_by_id);
 		if (link)
 			return gnome_cups_job_dup (link->data);
 	}



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