作図ソフト dia の改良版
リビジョン | 158e98c34e5e0c622eb0a04f39aeba3c5240c29d (tree) |
---|---|
日時 | 2014-10-02 06:52:08 |
作者 | Hans Breuer <hans@breu...> |
コミッター | Hans Breuer |
[warningectomy] format string is not a string literal (potentially insecure)
dia_xml.c:286:35: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
diacairo-print.c:248:20: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
xfig-export.c:275:21: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
load_save.c:1255:19: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
commands.c:507:35: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
@@ -504,7 +504,7 @@ _clipboard_get_data_callback (GtkClipboard *clipboard, | ||
504 | 504 | } |
505 | 505 | } |
506 | 506 | if (error) { |
507 | - dia_context_add_message (ctx, error->message); | |
507 | + dia_context_add_message (ctx, "%s", error->message); | |
508 | 508 | g_error_free (error); |
509 | 509 | } |
510 | 510 | dia_context_release (ctx); |
@@ -1252,7 +1252,7 @@ diagram_autosave(Diagram *dia) | ||
1252 | 1252 | asi->ctx = dia_context_new (_("Auto save")); |
1253 | 1253 | |
1254 | 1254 | if (!g_thread_create (_autosave_in_thread, asi, FALSE, &error)) { |
1255 | - message_error (error->message); | |
1255 | + message_error ("%s", error->message); | |
1256 | 1256 | g_error_free (error); |
1257 | 1257 | } |
1258 | 1258 | /* FIXME: need better synchronization */ |
@@ -283,7 +283,7 @@ xmlDiaParseFile(const char *filename, DiaContext *ctx) | ||
283 | 283 | ret = xmlDoParseFile(filename, &error_xml); |
284 | 284 | } |
285 | 285 | if (error_xml) |
286 | - dia_context_add_message (ctx, error_xml->message); | |
286 | + dia_context_add_message (ctx, "%s", error_xml->message); | |
287 | 287 | return ret; |
288 | 288 | } |
289 | 289 |
@@ -245,7 +245,7 @@ cairo_print_callback (DiagramData *data, | ||
245 | 245 | |
246 | 246 | res = gtk_print_operation_run (op, GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG, NULL, &error); |
247 | 247 | if (GTK_PRINT_OPERATION_RESULT_ERROR == res) { |
248 | - message_error (error->message); | |
248 | + message_error ("%s", error->message); | |
249 | 249 | g_error_free (error); |
250 | 250 | } |
251 | 251 | return NULL; |
@@ -272,7 +272,7 @@ static void | ||
272 | 272 | figWarn(XfigRenderer *renderer, int warning) |
273 | 273 | { |
274 | 274 | if (renderer->warnings[warning]) { |
275 | - message_warning(renderer->warnings[warning]); | |
275 | + message_warning("%s", renderer->warnings[warning]); | |
276 | 276 | renderer->warnings[warning] = NULL; |
277 | 277 | } |
278 | 278 | } |