summaryrefslogtreecommitdiffstats
path: root/src/util
diff options
context:
space:
mode:
authorKees Cook <kees@outflux.net>2007-03-20 17:16:36 +0000
committerkeescook <keescook@users.sourceforge.net>2007-03-20 17:16:36 +0000
commit4687a1c9ffe0d1d3f6ea01f360faa542a5b6491c (patch)
tree734a4d35a4e7b90593ae86a6c9006e58ce23d7d1 /src/util
parentpatch by cilix42 for bug 1671665 (diff)
downloadinkscape-4687a1c9ffe0d1d3f6ea01f360faa542a5b6491c.tar.gz
inkscape-4687a1c9ffe0d1d3f6ea01f360faa542a5b6491c.zip
format string protection/clean up (CVE-2007-1463, CVE-2007-1464)
(bzr r2720)
Diffstat (limited to 'src/util')
-rw-r--r--src/util/format.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/util/format.h b/src/util/format.h
index 3066173e1..80d79c28a 100644
--- a/src/util/format.h
+++ b/src/util/format.h
@@ -13,7 +13,7 @@
#define SEEN_INKSCAPE_UTIL_FORMAT_H
#include <stdarg.h>
-#include <glib/gstrfuncs.h>
+#include <glib.h>
#include "util/share.h"
namespace Inkscape {
@@ -27,6 +27,8 @@ inline ptr_shared<char> vformat(char const *format, va_list args) {
return result;
}
+ // needed since G_GNUC_PRINTF can only be used on a declaration
+ ptr_shared<char> format(char const *format, ...) G_GNUC_PRINTF(1,2);
inline ptr_shared<char> format(char const *format, ...) {
va_list args;