[findutils/f18] do not require gets() to be declared

Kamil Dudka kdudka at fedoraproject.org
Tue Aug 28 15:31:46 UTC 2012


commit da573c33097dcaac38a65b9aab8bea3fbb463935
Author: Kamil Dudka <kdudka at redhat.com>
Date:   Tue Aug 28 17:26:13 2012 +0200

    do not require gets() to be declared

 findutils-4.5.10-gets.patch |   29 +++++++++++++++++++++++++++++
 findutils.spec              |    5 +++++
 2 files changed, 34 insertions(+), 0 deletions(-)
---
diff --git a/findutils-4.5.10-gets.patch b/findutils-4.5.10-gets.patch
new file mode 100644
index 0000000..24eecc3
--- /dev/null
+++ b/findutils-4.5.10-gets.patch
@@ -0,0 +1,29 @@
+From fe7079ab7e5794b9222af5e56c6f25b424ca72f3 Mon Sep 17 00:00:00 2001
+From: Kamil Dudka <kdudka at redhat.com>
+Date: Tue, 28 Aug 2012 17:24:21 +0200
+Subject: [PATCH] gnulib: do not require gets() to be declared
+
+---
+ gnulib/lib/stdio.in.h |    6 ------
+ 1 files changed, 0 insertions(+), 6 deletions(-)
+
+diff --git a/gnulib/lib/stdio.in.h b/gnulib/lib/stdio.in.h
+index 57e93ba..b1e5bb6 100644
+--- a/gnulib/lib/stdio.in.h
++++ b/gnulib/lib/stdio.in.h
+@@ -175,12 +175,6 @@ _GL_WARN_ON_USE (fflush, "fflush is not always POSIX compliant - "
+                  "use gnulib module fflush for portable POSIX compliance");
+ #endif
+ 
+-/* It is very rare that the developer ever has full control of stdin,
+-   so any use of gets warrants an unconditional warning.  Assume it is
+-   always declared, since it is required by C89.  */
+-#undef gets
+-_GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
+-
+ #if @GNULIB_FOPEN@
+ # if @REPLACE_FOPEN@
+ #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
+-- 
+1.7.1
+
diff --git a/findutils.spec b/findutils.spec
index d5646ce..9517d50 100644
--- a/findutils.spec
+++ b/findutils.spec
@@ -25,6 +25,9 @@ Patch4: findutils-4.5.7-warnings.patch
 # configure.ac: do not use the AM_C_PROTOTYPES macro (removed in Automake 1.12)
 Patch5: findutils-4.5.10-automake.patch
 
+# gnulib: do not require gets() to be declared
+Patch6: findutils-4.5.10-gets.patch
+
 Requires(post): /sbin/install-info
 Requires(preun): /sbin/install-info
 Conflicts: filesystem < 3
@@ -56,6 +59,7 @@ useful for finding things on your system.
 %patch3 -p1
 %patch4 -p1
 %patch5 -p1
+%patch6 -p1
 
 # needed because of findutils-4.4.0-no-locate.patch
 aclocal -I gnulib/m4 -I m4
@@ -106,6 +110,7 @@ fi
 * Tue Aug 28 2012 Kamil Dudka <kdudka at redhat.com> - 1:4.5.10-7
 - fix specfile issues reported by the fedora-review script
 - do not use the AM_C_PROTOTYPES macro (removed in Automake 1.12)
+- do not require gets() to be declared
 
 * Thu Jul 19 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1:4.5.10-6
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild


More information about the scm-commits mailing list