[packages/aiksaurus] - fputs instead of printf to avoid format security error
witekfl
witekfl at pld-linux.org
Mon Jan 6 13:38:07 CET 2014
commit 39d1abb316b7c2994c03c91fd4e09d17278c4daf
Author: Witold Filipczyk <witekfl at poczta.onet.pl>
Date: Mon Jan 6 13:34:40 2014 +0100
- fputs instead of printf to avoid format security error
format_security.patch | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)
---
diff --git a/format_security.patch b/format_security.patch
new file mode 100644
index 0000000..4e7806c
--- /dev/null
+++ b/format_security.patch
@@ -0,0 +1,29 @@
+--- aiksaurus-1.2.1/base/caiksaurus.cpp.orig 2014-01-06 13:27:56.420352733 +0100
++++ aiksaurus-1.2.1/base/caiksaurus.cpp 2014-01-06 13:29:36.108561088 +0100
+@@ -254,7 +254,7 @@ static void handleArguments(int argc, ch
+ /* see if we got --version. */
+ if ( !strcmp(arg, "--version") || !strcmp(arg, "-v") )
+ {
+- printf(version);
++ fputs(version, stdout);
+ exit(0);
+ }
+
+@@ -262,7 +262,7 @@ static void handleArguments(int argc, ch
+ else if ( !strcmp(arg, "--help") || !strcmp(arg, "-h") )
+ {
+ printf("Usage: %s [word]\n\n", argv[0]);
+- printf(help);
++ fputs(help, stdout);
+ exit(0);
+ }
+ }
+@@ -271,7 +271,7 @@ static void handleArguments(int argc, ch
+ if (argc != 2)
+ {
+ printf("Usage: %s [word]\n", argv[0]);
+- printf(help);
++ fputs(help, stdout);
+ exit(1);
+ }
+ }
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/aiksaurus.git/commitdiff/792ad8f129d4c259301818d49860a9f9241d7135
More information about the pld-cvs-commit
mailing list