[evolution: 1437/1446] Fix compiler warnings.



commit c75f58d01bb7bbe139cd73a85894dc5f50185816
Author: Matthew Barnes <mbarnes redhat com>
Date:   Fri Nov 18 09:58:44 2011 -0500

    Fix compiler warnings.

 calendar/gui/alarm-notify/config-data.c         |    2 +-
 calendar/gui/gnome-cal.c                        |    1 -
 capplet/settings/mail-account-view.c            |    3 +--
 composer/e-msg-composer.c                       |    4 +---
 e-util/e-plugin.c                               |    5 +++--
 em-format/em-format.c                           |    2 --
 mail/e-mail-attachment-bar.c                    |    1 -
 mail/e-mail-browser.c                           |    1 -
 mail/e-mail-label-list-store.c                  |    4 +++-
 mail/e-mail-reader.c                            |    1 -
 mail/e-mail-session.c                           |    2 --
 mail/em-composer-utils.c                        |    2 --
 mail/em-folder-properties.c                     |    1 -
 mail/message-list.c                             |    1 -
 modules/addressbook/e-book-shell-view-actions.c |    1 -
 modules/calendar/e-cal-shell-content.c          |    1 -
 modules/calendar/e-cal-shell-sidebar.c          |    1 -
 modules/calendar/e-memo-shell-view-actions.c    |    1 -
 modules/mail/e-mail-shell-backend.c             |    4 ----
 plugins/itip-formatter/itip-formatter.c         |    5 +++--
 plugins/save-calendar/rdf-format.c              |    2 --
 shell/e-shell-migrate.c                         |    1 -
 shell/e-shell-settings.c                        |    1 -
 shell/e-shell.c                                 |    5 ++---
 widgets/table/e-table-field-chooser-item.c      |    1 -
 25 files changed, 14 insertions(+), 39 deletions(-)
---
diff --git a/calendar/gui/alarm-notify/config-data.c b/calendar/gui/alarm-notify/config-data.c
index 910e786..c8348f8 100644
--- a/calendar/gui/alarm-notify/config-data.c
+++ b/calendar/gui/alarm-notify/config-data.c
@@ -340,7 +340,7 @@ config_data_save_blessed_program (const gchar *program)
 	for (i = 0; i < g_strv_length (list); i++)
 		g_ptr_array_add (array, list[i]);
 
-	g_ptr_array_add (array, program);
+	g_ptr_array_add (array, (gpointer) program);
 	g_ptr_array_add (array, NULL);
 	g_settings_set_strv (calendar_settings, "notify-programs", (const gchar *const *) array->pdata);
 
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c
index 6fd5153..aa0aebf 100644
--- a/calendar/gui/gnome-cal.c
+++ b/calendar/gui/gnome-cal.c
@@ -1480,7 +1480,6 @@ gnome_calendar_init (GnomeCalendar *gcal)
 static void
 gnome_calendar_do_dispose (GObject *object)
 {
-	GList *l;
 	GnomeCalendar *gcal;
 	GnomeCalendarPrivate *priv;
 	gint ii;
diff --git a/capplet/settings/mail-account-view.c b/capplet/settings/mail-account-view.c
index e6fd53b..5947440 100644
--- a/capplet/settings/mail-account-view.c
+++ b/capplet/settings/mail-account-view.c
@@ -250,7 +250,7 @@ add_selected_calendar (const gchar *uid)
 	array = g_ptr_array_new ();
 	for (i = 0; ids[i] != NULL; i++)
 		g_ptr_array_add (array, ids[i]);
-	g_ptr_array_add (array, uid);
+	g_ptr_array_add (array, (gpointer) uid);
 	g_ptr_array_add (array, NULL);
 
 	g_settings_set_strv (settings, "selected-calendars", (const gchar* const *) array->pdata);
@@ -369,7 +369,6 @@ setup_google_accounts (MailAccountView *mav)
 		ESourceGroup *sgrp;
 		ESource *calendar;
 		gchar *sanitize_uname, *abs_uri, *rel_uri;
-		GSList *ids, *temp;
 
 		slist = e_source_list_new_for_gconf (gconf, "/apps/evolution/calendar/sources");
 		sgrp = e_source_list_ensure_group (slist, _("Google"), "google://", TRUE);
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 3b7208d..bdca1d8 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -2065,10 +2065,8 @@ msg_composer_constructed (GObject *object)
 	EWebView *web_view;
 	GtkUIManager *ui_manager;
 	GtkToggleAction *action;
-	GArray *array;
 	const gchar *id;
 	gboolean active;
-	guint binding_id;
 
 	editor = GTKHTML_EDITOR (object);
 	composer = E_MSG_COMPOSER (object);
@@ -5087,7 +5085,7 @@ e_save_spell_languages (GList *spell_languages)
 
 		language = spell_languages->data;
 		language_code = gtkhtml_spell_language_get_code (language);
-		g_ptr_array_add (lang_array, language_code);
+		g_ptr_array_add (lang_array, (gpointer) language_code);
 
 		spell_languages = g_list_next (spell_languages);
 	}
diff --git a/e-util/e-plugin.c b/e-util/e-plugin.c
index 6eba330..f839591 100644
--- a/e-util/e-plugin.c
+++ b/e-util/e-plugin.c
@@ -131,8 +131,9 @@ ep_set_enabled (const gchar *id,
 	for (l = ep_disabled; l != NULL; l = l->next)
 		g_ptr_array_add (array, l->data);
 	g_ptr_array_add (array, NULL);
-	g_settings_set_strv (settings, "disabled-eplugins", array->pdata);
-
+	g_settings_set_strv (
+		settings, "disabled-eplugins",
+		(const gchar * const *) array->pdata);
 	g_ptr_array_free (array, TRUE);
 	g_object_unref (settings);
 }
diff --git a/em-format/em-format.c b/em-format/em-format.c
index b83d39e..4647a70 100644
--- a/em-format/em-format.c
+++ b/em-format/em-format.c
@@ -1363,7 +1363,6 @@ em_format_format_text (EMFormat *emf,
 	const gchar *charset = NULL;
 	CamelMimeFilterWindows *windows = NULL;
 	CamelStream *mem_stream = NULL;
-	const gchar *key;
 	gsize size;
 	gsize max;
 	GSettings *settings;
@@ -1413,7 +1412,6 @@ em_format_format_text (EMFormat *emf,
 
 	settings = g_settings_new ("org.gnome.evolution.mail");
 	if (g_settings_get_boolean (settings, "force-message-limit")) {
-		key = "/apps/evolution/mail/display/message_text_part_limit";
 		max = g_settings_get_int (settings, "message-text-part-limit");
 		if (max == 0)
 			max = -1;
diff --git a/mail/e-mail-attachment-bar.c b/mail/e-mail-attachment-bar.c
index f3567f2..c07d0e8 100644
--- a/mail/e-mail-attachment-bar.c
+++ b/mail/e-mail-attachment-bar.c
@@ -256,7 +256,6 @@ mail_attachment_bar_constructed (GObject *object)
 {
 	EMailAttachmentBarPrivate *priv;
 	GSettings *settings;
-	const gchar *key;
 
 	priv = E_MAIL_ATTACHMENT_BAR (object)->priv;
 
diff --git a/mail/e-mail-browser.c b/mail/e-mail-browser.c
index aaa12b1..1125510 100644
--- a/mail/e-mail-browser.c
+++ b/mail/e-mail-browser.c
@@ -559,7 +559,6 @@ mail_browser_constructed (GObject *object)
 	GtkWidget *widget;
 	EWebView *web_view;
 	const gchar *domain;
-	const gchar *key;
 	const gchar *id;
 	guint merge_id;
 
diff --git a/mail/e-mail-label-list-store.c b/mail/e-mail-label-list-store.c
index 5ceacb0..ed8efb7 100644
--- a/mail/e-mail-label-list-store.c
+++ b/mail/e-mail-label-list-store.c
@@ -202,7 +202,9 @@ labels_model_changed_cb (GtkTreeModel *model,
 	}
 
 	g_ptr_array_add (array, NULL);
-	g_settings_set_strv (store->priv->mail_settings, "labels", array->pdata);
+	g_settings_set_strv (
+		store->priv->mail_settings, "labels",
+		(const gchar * const *) array->pdata);
 
 	g_ptr_array_free (array, TRUE);
 	g_signal_handlers_unblock_by_func (store->priv->mail_settings, labels_settings_changed_cb, store);
diff --git a/mail/e-mail-reader.c b/mail/e-mail-reader.c
index 0a48f3d..22b1e0e 100644
--- a/mail/e-mail-reader.c
+++ b/mail/e-mail-reader.c
@@ -3427,7 +3427,6 @@ e_mail_reader_init (EMailReader *reader,
 	GtkAction *action;
 	gboolean sensitive;
 	const gchar *action_name;
-	const gchar *key;
 
 #ifndef G_OS_WIN32
 	GSettings *settings;
diff --git a/mail/e-mail-session.c b/mail/e-mail-session.c
index f4fcbb2..4f863af 100644
--- a/mail/e-mail-session.c
+++ b/mail/e-mail-session.c
@@ -70,8 +70,6 @@
 	(G_TYPE_INSTANCE_GET_PRIVATE \
 	((obj), E_TYPE_MAIL_SESSION, EMailSessionPrivate))
 
-static guint session_check_junk_notify_id;
-
 typedef struct _AsyncContext AsyncContext;
 
 struct _EMailSessionPrivate {
diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c
index 85fc96d..e571e84 100644
--- a/mail/em-composer-utils.c
+++ b/mail/em-composer-utils.c
@@ -2792,7 +2792,6 @@ composer_set_body (EMsgComposer *composer,
 	GSettings *settings;
 	gboolean start_bottom, has_body_text = FALSE;
 	guint32 validity_found = 0;
-	const gchar *key;
 
 	settings = g_settings_new ("org.gnome.evolution.mail");
 
@@ -2839,7 +2838,6 @@ composer_set_body (EMsgComposer *composer,
 		GtkhtmlEditor *editor = GTKHTML_EDITOR (composer);
 		gboolean move_cursor_to_end;
 		gboolean top_signature;
-		const gchar *key;
 
 		/* If we are placing signature on top, then move cursor to the end,
 		 * otherwise try to find the signature place and place cursor just
diff --git a/mail/em-folder-properties.c b/mail/em-folder-properties.c
index 6c8b97a..310aa76 100644
--- a/mail/em-folder-properties.c
+++ b/mail/em-folder-properties.c
@@ -254,7 +254,6 @@ emfp_dialog_run (AsyncContext *context)
 	gboolean hide_deleted;
 	GSettings *settings;
 	const gchar *name;
-	const gchar *key;
 
 	shell_view = context->shell_view;
 	shell_window = e_shell_view_get_shell_window (shell_view);
diff --git a/mail/message-list.c b/mail/message-list.c
index e979335..1b8f0d1 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -5010,7 +5010,6 @@ mail_regen_list (MessageList *ml,
 {
 	struct _regen_list_msg *m;
 	GSettings *settings;
-	const gchar *key;
 	gboolean thread_subject;
 
 	/* report empty search as NULL, not as one/two-space string */
diff --git a/modules/addressbook/e-book-shell-view-actions.c b/modules/addressbook/e-book-shell-view-actions.c
index e967b11..7373605 100644
--- a/modules/addressbook/e-book-shell-view-actions.c
+++ b/modules/addressbook/e-book-shell-view-actions.c
@@ -1150,7 +1150,6 @@ e_book_shell_view_actions_init (EBookShellView *book_shell_view)
 	GSettings *settings;
 	GtkAction *action;
 	GObject *object;
-	const gchar *key;
 
 	shell_view = E_SHELL_VIEW (book_shell_view);
 	shell_window = e_shell_view_get_shell_window (shell_view);
diff --git a/modules/calendar/e-cal-shell-content.c b/modules/calendar/e-cal-shell-content.c
index 5e60ecd..e2e1ce5 100644
--- a/modules/calendar/e-cal-shell-content.c
+++ b/modules/calendar/e-cal-shell-content.c
@@ -328,7 +328,6 @@ cal_shell_content_constructed (GObject *object)
 	GSettings *settings;
 	GtkWidget *container;
 	GtkWidget *widget;
-	const gchar *key;
 	gchar *markup;
 	gint ii;
 
diff --git a/modules/calendar/e-cal-shell-sidebar.c b/modules/calendar/e-cal-shell-sidebar.c
index f896db6..c73ca8a 100644
--- a/modules/calendar/e-cal-shell-sidebar.c
+++ b/modules/calendar/e-cal-shell-sidebar.c
@@ -526,7 +526,6 @@ cal_shell_sidebar_restore_state_cb (EShellWindow *shell_window,
 	GtkTreeModel *model;
 	GSList *list, *iter;
 	GObject *object;
-	const gchar *key;
 
 	priv = E_CAL_SHELL_SIDEBAR (shell_sidebar)->priv;
 
diff --git a/modules/calendar/e-memo-shell-view-actions.c b/modules/calendar/e-memo-shell-view-actions.c
index c832066..3a08746 100644
--- a/modules/calendar/e-memo-shell-view-actions.c
+++ b/modules/calendar/e-memo-shell-view-actions.c
@@ -866,7 +866,6 @@ e_memo_shell_view_actions_init (EMemoShellView *memo_shell_view)
 	GSettings *memo_settings;
 	GtkAction *action;
 	GObject *object;
-	const gchar *key;
 
 	shell_view = E_SHELL_VIEW (memo_shell_view);
 	shell_window = e_shell_view_get_shell_window (shell_view);
diff --git a/modules/mail/e-mail-shell-backend.c b/modules/mail/e-mail-shell-backend.c
index f498621..5ea75ee 100644
--- a/modules/mail/e-mail-shell-backend.c
+++ b/modules/mail/e-mail-shell-backend.c
@@ -477,12 +477,10 @@ mail_shell_backend_delete_junk_policy_decision (EMailBackend *backend)
 	EShell *shell;
 	EShellSettings *shell_settings;
 	GSettings *settings;
-	const gchar *key;
 	gboolean delete_junk;
 	gint empty_date;
 	gint empty_days;
 	gint now;
-	GError *error = NULL;
 
 	shell = e_shell_backend_get_shell (E_SHELL_BACKEND (backend));
 
@@ -520,12 +518,10 @@ mail_shell_backend_empty_trash_policy_decision (EMailBackend *backend)
 	EShell *shell;
 	EShellSettings *shell_settings;
 	GSettings *settings;
-	const gchar *key;
 	gboolean empty_trash;
 	gint empty_date;
 	gint empty_days;
 	gint now;
-	GError *error = NULL;
 
 	shell = e_shell_backend_get_shell (E_SHELL_BACKEND (backend));
 
diff --git a/plugins/itip-formatter/itip-formatter.c b/plugins/itip-formatter/itip-formatter.c
index c6852b7..ba649ea 100644
--- a/plugins/itip-formatter/itip-formatter.c
+++ b/plugins/itip-formatter/itip-formatter.c
@@ -2950,10 +2950,11 @@ delete_toggled_cb (GtkWidget *widget,
                    gpointer data)
 {
 	GSettings *settings;
-	EMConfigTargetPrefs *target = data;
+	gboolean active;
 
 	settings = g_settings_new ("org.gnome.evolution.eplugin.itip");
-	g_settings_set_boolean (settings, CONF_KEY_DELETE, gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)));
+	active = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget));
+	g_settings_set_boolean (settings, CONF_KEY_DELETE, active);
 	g_object_unref (settings);
 }
 
diff --git a/plugins/save-calendar/rdf-format.c b/plugins/save-calendar/rdf-format.c
index ed9cf18..fe2e6d0 100644
--- a/plugins/save-calendar/rdf-format.c
+++ b/plugins/save-calendar/rdf-format.c
@@ -54,8 +54,6 @@ static void	add_string_to_rdf		(xmlNodePtr node,
 #define CALENDAR_CONFIG_PREFIX "/apps/evolution/calendar"
 #define CALENDAR_CONFIG_TIMEZONE CALENDAR_CONFIG_PREFIX "/display/timezone"
 
-static GConfClient *config = NULL;
-
 static gchar *
 calendar_config_get_timezone (void)
 {
diff --git a/shell/e-shell-migrate.c b/shell/e-shell-migrate.c
index 1931011..b0fa40d 100644
--- a/shell/e-shell-migrate.c
+++ b/shell/e-shell-migrate.c
@@ -901,7 +901,6 @@ e_shell_migrate_attempt (EShell *shell)
 	ESEvent *ese;
 	GSettings *settings;
 	GConfClient *client;
-	const gchar *key;
 	gint major, minor, micro;
 	gint last_major, last_minor, last_micro;
 	gint curr_major, curr_minor, curr_micro;
diff --git a/shell/e-shell-settings.c b/shell/e-shell-settings.c
index 5bffa8d..0fd8d10 100644
--- a/shell/e-shell-settings.c
+++ b/shell/e-shell-settings.c
@@ -49,7 +49,6 @@ shell_settings_pspec_for_key (const gchar *property_name,
 	GVariant *v;
 	GParamSpec *pspec;
 	const gchar *bad_type;
-	GError *error = NULL;
 
 	settings = g_settings_new (schema);
 
diff --git a/shell/e-shell.c b/shell/e-shell.c
index 267c837..ccc57f8 100644
--- a/shell/e-shell.c
+++ b/shell/e-shell.c
@@ -1432,11 +1432,10 @@ e_shell_create_shell_window (EShell *shell,
 	 * so set the key ahead of time to control the intial view. */
 	if (view_name != NULL) {
 		GSettings *settings;
-		const gchar *key;
 
 		settings = g_settings_new ("org.gnome.evolution.shell");
-		g_settings_set_string (settings, "default-component-id", view_name);
-
+		g_settings_set_string (
+			settings, "default-component-id", view_name);
 		g_object_unref (settings);
 	}
 
diff --git a/widgets/table/e-table-field-chooser-item.c b/widgets/table/e-table-field-chooser-item.c
index 78d8461..d8fd541 100644
--- a/widgets/table/e-table-field-chooser-item.c
+++ b/widgets/table/e-table-field-chooser-item.c
@@ -564,7 +564,6 @@ etfci_start_drag (ETableFieldChooserItem *etfci,
 	cairo_t *cr;
 	gint drag_col;
 	gint button_height;
-	GdkPixbuf *pixbuf;
 
 	GtkTargetEntry  etfci_drag_types[] = {
 		{ (gchar *) TARGET_ETABLE_COL_TYPE, 0, TARGET_ETABLE_COL_HEADER },



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