summaryrefslogtreecommitdiffhomepage
path: root/mixlib
diff options
context:
space:
mode:
authorJose Antonio Ortega Ruiz <jao@imladris>2014-05-21 05:25:26 +0200
committerJose Antonio Ortega Ruiz <jao@imladris>2014-05-21 05:25:26 +0200
commit63fab7aaf443112feb6f5ddcab0fafe8b5911af9 (patch)
tree51abb961e2ef1ae3e8a4ab5f34d99b1aae7b4211 /mixlib
parent89522e543d73e04c1e0204e287d53e27079cdab7 (diff)
downloadmdk-63fab7aaf443112feb6f5ddcab0fafe8b5911af9.tar.gz
mdk-63fab7aaf443112feb6f5ddcab0fafe8b5911af9.tar.bz2
Avoiding format strings security warnings (cf. #8467)
Diffstat (limited to 'mixlib')
-rw-r--r--mixlib/mix.c6
-rw-r--r--mixlib/mix_ins.c2
-rw-r--r--mixlib/xmix_vm_handlers.c10
3 files changed, 9 insertions, 9 deletions
diff --git a/mixlib/mix.c b/mixlib/mix.c
index 2452cdf..0c992b1 100644
--- a/mixlib/mix.c
+++ b/mixlib/mix.c
@@ -1,7 +1,7 @@
/* -*-c-*- -------------- mix.c :
* Implementation of the functions declared in mix.h
* ------------------------------------------------------------------
- * Copyright (C) 2000, 2001, 2002, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
+ * Copyright (C) 2000, 2001, 2002, 2005, 2006, 2007, 2008, 2009, 2014 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -53,7 +53,7 @@ mix_release_lib (void)
}
const char *MIX_GPL_LICENSE =
-"Copyright (C) 2000-2009 Free Software Foundation, Inc.\n"
+"Copyright (C) 2000-2014 Free Software Foundation, Inc.\n"
"There is NO warranty. You may redistribute this software\n"
"under the terms of the GNU General Public License.\n"
"For more information about these matters, see the files named COPYING.\n";
@@ -62,7 +62,7 @@ void
mix_print_license (const gchar *program)
{
fprintf (stderr, _("%s (GNU MDK %s)\n\n"), program, VERSION);
- fprintf (stderr, MIX_GPL_LICENSE);
+ fprintf (stderr, "%s", MIX_GPL_LICENSE);
}
/* check dir, and create it if it doesn't exist */
diff --git a/mixlib/mix_ins.c b/mixlib/mix_ins.c
index 663591d..42cdafc 100644
--- a/mixlib/mix_ins.c
+++ b/mixlib/mix_ins.c
@@ -261,7 +261,7 @@ void
mix_ins_print (const mix_ins_t *ins)
{
g_return_if_fail (ins != NULL);
- g_print (mix_get_string_from_id (mix_ins_id_from_ins (*ins)));
+ g_print ("%s", mix_get_string_from_id (mix_ins_id_from_ins (*ins)));
g_print (" %s%d,%d(%d:%d)", mix_short_is_negative (ins->address) ? "-" : "+",
mix_short_magnitude (ins->address), ins->index,
mix_fspec_left (ins->fspec), mix_fspec_right (ins->fspec));
diff --git a/mixlib/xmix_vm_handlers.c b/mixlib/xmix_vm_handlers.c
index b856709..a567f38 100644
--- a/mixlib/xmix_vm_handlers.c
+++ b/mixlib/xmix_vm_handlers.c
@@ -1,7 +1,7 @@
/* -*-c-*- -------------- xmix_vm_handlers.c :
* Implementation of the functions declared in xmix_vm_handlers.h
* ------------------------------------------------------------------
- * Copyright (C) 2001, 2002, 2003, 2004, 2006, 2007, 2010 Free Software Foundation, Inc.
+ * Copyright (C) 2001, 2002, 2003, 2004, 2006, 2007, 2010, 2014 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -1360,8 +1360,8 @@ gboolean
cmd_pprog_ (mix_vm_cmd_dispatcher_t *dis, const gchar *arg)
{
const gchar *path = mix_vm_cmd_dispatcher_get_program_path (dis);
- fprintf (dis->out, path? path : _("No program currently loaded"));
- fprintf (dis->out, "\n");
+ fprintf (dis->out, "%s", path? path : _("No program currently loaded"));
+ fprintf (dis->out, "%s", "\n");
return (path != NULL);
}
@@ -1369,8 +1369,8 @@ gboolean
cmd_psrc_ (mix_vm_cmd_dispatcher_t *dis, const gchar *arg)
{
const gchar *path = mix_vm_cmd_dispatcher_get_src_file_path (dis);
- fprintf (dis->out, path? path : _("No program currently loaded\n"));
- fprintf (dis->out, "\n");
+ fprintf (dis->out, "%s", path? path : _("No program currently loaded\n"));
+ fprintf (dis->out, "%s", "\n");
return (path != NULL);
}