2
1

diffutils-gets-no-longer-exists-in-eglibc-2.16.patch 849 B

1234567891011121314151617181920212223242526
  1. Handle the fact that gets() no longer exists in glibc >= 2.16
  2. The problem has been fixed upstream, but no release containing the fix
  3. has been made so far.
  4. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
  5. Index: b/lib/stdio.in.h
  6. ===================================================================
  7. --- a/lib/stdio.in.h
  8. +++ b/lib/stdio.in.h
  9. @@ -693,12 +693,14 @@
  10. _GL_CXXALIAS_SYS (gets, char *, (char *s));
  11. # undef gets
  12. # endif
  13. +# if defined gets
  14. _GL_CXXALIASWARN (gets);
  15. /* It is very rare that the developer ever has full control of stdin,
  16. so any use of gets warrants an unconditional warning. Assume it is
  17. always declared, since it is required by C89. */
  18. _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
  19. #endif
  20. +#endif
  21. #if @GNULIB_OBSTACK_PRINTF@ || @GNULIB_OBSTACK_PRINTF_POSIX@