From: Cosimo Cecchi Date: Tue, 10 Jun 2008 18:10:50 +0000 (+0000) Subject: Fix some build warnings under GCC 4.3.0. (#537535). X-Git-Tag: EVINCE_2_23_4~5 X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=commitdiff_plain;h=0d0c2500e6383c5e7821d6fb10ea1fb0307a36b6;p=evince.git Fix some build warnings under GCC 4.3.0. (#537535). 2008-06-10 Cosimo Cecchi * libdocument/ev-backends-manager.c: (ev_backends_manager_load): * libdocument/ev-image.c: (ev_image_save_tmp): * libdocument/ev-module.c: (ev_module_load): * shell/ev-application.c: (ev_application_shutdown), (ev_application_get_print_settings): * shell/ev-sidebar-attachments.c: (ev_sidebar_attachments_button_press), (ev_sidebar_attachments_drag_data_get): * shell/ev-window.c: (window_save_file_copy_ready_cb), (ev_window_print_finished), (ev_window_print_send), (ev_window_print_job_cb), (ev_window_cmd_help_contents), (ev_window_preview_print_finished), (ev_window_do_preview_print), (ev_window_cmd_preview_print): * shell/main.c: (load_files_remote): Fix some build warnings under GCC 4.3.0. (#537535). svn path=/trunk/; revision=3049 --- diff --git a/ChangeLog b/ChangeLog index 893cb951..ad55bbe9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,21 @@ +2008-06-10 Cosimo Cecchi + + * libdocument/ev-backends-manager.c: (ev_backends_manager_load): + * libdocument/ev-image.c: (ev_image_save_tmp): + * libdocument/ev-module.c: (ev_module_load): + * shell/ev-application.c: (ev_application_shutdown), + (ev_application_get_print_settings): + * shell/ev-sidebar-attachments.c: + (ev_sidebar_attachments_button_press), + (ev_sidebar_attachments_drag_data_get): + * shell/ev-window.c: (window_save_file_copy_ready_cb), + (ev_window_print_finished), (ev_window_print_send), + (ev_window_print_job_cb), (ev_window_cmd_help_contents), + (ev_window_preview_print_finished), (ev_window_do_preview_print), + (ev_window_cmd_preview_print): + * shell/main.c: (load_files_remote): + Fix some build warnings under GCC 4.3.0. (#537535). + 2008-05-29 Carlos Garcia Campos * shell/ev-jobs.c: (ev_job_render_dispose): diff --git a/libdocument/ev-backends-manager.c b/libdocument/ev-backends-manager.c index 28672dfc..505d5c4d 100644 --- a/libdocument/ev-backends-manager.c +++ b/libdocument/ev-backends-manager.c @@ -118,7 +118,7 @@ ev_backends_manager_load (void) dir = g_dir_open (EV_BACKENDSDIR, 0, &error); if (!dir) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); return FALSE; diff --git a/libdocument/ev-image.c b/libdocument/ev-image.c index 1fa6bfd6..fa4cccf5 100644 --- a/libdocument/ev-image.c +++ b/libdocument/ev-image.c @@ -152,7 +152,7 @@ ev_image_save_tmp (EvImage *image, } /* Erro saving image */ - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); g_free (filename); diff --git a/libdocument/ev-module.c b/libdocument/ev-module.c index f9860a2f..65627ab1 100644 --- a/libdocument/ev-module.c +++ b/libdocument/ev-module.c @@ -76,7 +76,7 @@ ev_module_load (GTypeModule *gmodule) module->library = g_module_open (module->path, 0); if (!module->library) { - g_warning (g_module_error ()); + g_warning ("%s", g_module_error ()); return FALSE; } @@ -84,7 +84,7 @@ ev_module_load (GTypeModule *gmodule) /* extract symbols from the lib */ if (!g_module_symbol (module->library, "register_evince_backend", (void *) ®ister_func)) { - g_warning (g_module_error ()); + g_warning ("%s", g_module_error ()); g_module_close (module->library); return FALSE; diff --git a/shell/ev-application.c b/shell/ev-application.c index d4a1d1fa..6e7a6e67 100644 --- a/shell/ev-application.c +++ b/shell/ev-application.c @@ -645,7 +645,7 @@ ev_application_shutdown (EvApplication *application) application->print_settings_file, &error); if (error) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); } @@ -803,7 +803,7 @@ ev_application_get_print_settings (EvApplication *application) gtk_print_settings_new_from_file (application->print_settings_file, &error); if (error) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); } else { return application->print_settings; diff --git a/shell/ev-sidebar-attachments.c b/shell/ev-sidebar-attachments.c index 7fb7f00e..2aeadd69 100644 --- a/shell/ev-sidebar-attachments.c +++ b/shell/ev-sidebar-attachments.c @@ -295,7 +295,7 @@ ev_sidebar_attachments_button_press (EvSidebarAttachments *ev_attachbar, ev_attachment_open (attachment, &error); if (error) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); } @@ -434,7 +434,7 @@ ev_sidebar_attachments_drag_data_get (GtkWidget *widget, } if (error) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); } diff --git a/shell/ev-window.c b/shell/ev-window.c index e981cafc..f6a52542 100644 --- a/shell/ev-window.c +++ b/shell/ev-window.c @@ -1941,7 +1941,7 @@ window_save_file_copy_ready_cb (GFile *src, _("The file could not be saved as “%s”."), name); gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog), - error->message); + "%s", error->message); g_signal_connect (dialog, "response", G_CALLBACK (gtk_widget_destroy), NULL); @@ -2156,7 +2156,7 @@ ev_window_print_finished (GtkPrintJob *print_job, GTK_BUTTONS_OK, _("Failed to print document")); gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog), - error->message); + "%s", error->message); gtk_dialog_run (GTK_DIALOG (dialog)); gtk_widget_destroy (dialog); @@ -2243,7 +2243,7 @@ ev_window_print_send (EvWindow *window, window, NULL); } else { ev_window_clear_print_job (window); - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); } } @@ -2256,7 +2256,7 @@ ev_window_print_job_cb (EvJobPrint *job, EvWindow *window) { if (job->error) { - g_warning (job->error->message); + g_warning ("%s", job->error->message); ev_window_clear_print_job (window); return; } @@ -3250,7 +3250,7 @@ ev_window_cmd_help_contents (GtkAction *action, EvWindow *ev_window) screen = gtk_widget_get_screen (GTK_WIDGET (ev_window)); gdk_spawn_command_line_on_screen (screen, command, &error); if (error != NULL) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); } g_free (command); @@ -3306,7 +3306,7 @@ ev_window_preview_print_finished (GtkPrintJob *print_job, GTK_BUTTONS_OK, _("Failed to print document")); gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog), - error->message); + "%s", error->message); gtk_dialog_run (GTK_DIALOG (dialog)); gtk_widget_destroy (dialog); @@ -3350,7 +3350,7 @@ ev_window_do_preview_print (EvWindow *window) (GtkPrintJobCompleteFunc)ev_window_preview_print_finished, window, NULL); } else { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); } @@ -3375,7 +3375,7 @@ ev_window_cmd_preview_print (GtkAction *action, EvWindow *window) &error); if (error) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); print_settings = NULL; } diff --git a/shell/main.c b/shell/main.c index a552a328..04aa5ea1 100644 --- a/shell/main.c +++ b/shell/main.c @@ -252,7 +252,7 @@ load_files_remote (const char **files, connection = dbus_g_bus_get (DBUS_BUS_STARTER, &error); if (connection == NULL) { - g_warning (error->message); + g_warning ("%s", error->message); g_error_free (error); return FALSE; @@ -268,7 +268,7 @@ load_files_remote (const char **files, G_TYPE_UINT, timestamp, G_TYPE_INVALID, G_TYPE_INVALID)) { - g_warning (error->message); + g_warning ("%s", error->message); g_clear_error (&error); g_object_unref (remote_object); dbus_g_connection_unref (connection); @@ -298,7 +298,7 @@ load_files_remote (const char **files, G_TYPE_UINT, timestamp, G_TYPE_INVALID, G_TYPE_INVALID)) { - g_warning (error->message); + g_warning ("%s", error->message); g_clear_error (&error); g_free (uri); continue;