[sysprof] Fix build with -Werror=format-security



commit 4e77734d490f1a077f474db1bc51ea5e1c4f2206
Author: Pascal Terjan <pterjan mandriva com>
Date:   Tue Mar 23 17:21:37 2010 +0100

    Fix build with -Werror=format-security
    
    Don't use dynamic string as format, one of the args could be a string
    containing %.

 sysprof.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/sysprof.c b/sysprof.c
index be87247..cc676a9 100644
--- a/sysprof.c
+++ b/sysprof.c
@@ -333,7 +333,7 @@ sorry (GtkWidget *parent_window,
     dialog = gtk_message_dialog_new (parent_window ? GTK_WINDOW (parent_window) : NULL,
 				     GTK_DIALOG_DESTROY_WITH_PARENT,
 				     GTK_MESSAGE_WARNING,
-				     GTK_BUTTONS_OK, message);
+				     GTK_BUTTONS_OK, "%s", message);
     g_free (message);
 
     gtk_window_set_title (GTK_WINDOW (dialog), APPLICATION_NAME " Warning");



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