summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Natterer <mitch@imendio.com>2008-04-18 14:51:26 +0000
committerMichael Natterer <mitch@src.gnome.org>2008-04-18 14:51:26 +0000
commit870bac8fd0515c8c383ff47a13192e898da4c485 (patch)
tree3fea0b30e6a078e601412bf27d3508143ab74c27
parent6d683653db2da65dd5419a90b6f4a6972a76b0b3 (diff)
downloadgtk+-870bac8fd0515c8c383ff47a13192e898da4c485.tar.gz
change return value and local variable to const gchar* to fix warning
2008-04-18 Michael Natterer <mitch@imendio.com> * modules/printbackends/cups/gtkprintercups.[ch] (gtk_printer_cups_get_ppd_name): change return value and local variable to const gchar* to fix warning about discarding const qualifier. svn path=/trunk/; revision=20021
-rw-r--r--ChangeLog7
-rw-r--r--modules/printbackends/cups/gtkprintercups.c5
-rw-r--r--modules/printbackends/cups/gtkprintercups.h4
3 files changed, 11 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 14d9c83d77..f6c5cdccb7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2008-04-18 Michael Natterer <mitch@imendio.com>
+
+ * modules/printbackends/cups/gtkprintercups.[ch]
+ (gtk_printer_cups_get_ppd_name): change return value and local
+ variable to const gchar* to fix warning about discarding const
+ qualifier.
+
2008-04-18 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentmanager.c:
diff --git a/modules/printbackends/cups/gtkprintercups.c b/modules/printbackends/cups/gtkprintercups.c
index 21ae2c6837..e54361957b 100644
--- a/modules/printbackends/cups/gtkprintercups.c
+++ b/modules/printbackends/cups/gtkprintercups.c
@@ -127,10 +127,10 @@ gtk_printer_cups_get_ppd (GtkPrinterCups *printer)
return printer->ppd_file;
}
-char *
+const gchar *
gtk_printer_cups_get_ppd_name (GtkPrinterCups *printer)
{
- gchar *result;
+ const gchar *result;
result = printer->ppd_name;
@@ -139,4 +139,3 @@ gtk_printer_cups_get_ppd_name (GtkPrinterCups *printer)
return result;
}
-
diff --git a/modules/printbackends/cups/gtkprintercups.h b/modules/printbackends/cups/gtkprintercups.h
index d33a5ab5eb..7e2734703f 100644
--- a/modules/printbackends/cups/gtkprintercups.h
+++ b/modules/printbackends/cups/gtkprintercups.h
@@ -16,10 +16,10 @@
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
+
#ifndef __GTK_PRINTER_CUPS_H__
#define __GTK_PRINTER_CUPS_H__
-#include <glib.h>
#include <glib-object.h>
#include <cups/cups.h>
#include <cups/ppd.h>
@@ -65,7 +65,7 @@ void gtk_printer_cups_register_type (GTypeModule *module
GtkPrinterCups *gtk_printer_cups_new (const char *name,
GtkPrintBackend *backend);
ppd_file_t *gtk_printer_cups_get_ppd (GtkPrinterCups *printer);
-char *gtk_printer_cups_get_ppd_name (GtkPrinterCups *printer);
+const gchar *gtk_printer_cups_get_ppd_name (GtkPrinterCups *printer);
G_END_DECLS