mirror of
https://sourceware.org/git/glibc.git
synced 2025-08-07 06:43:00 +03:00
Better gets prototype and fallout from removal
This commit is contained in:
@@ -638,7 +638,7 @@ extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream)
|
|||||||
|
|
||||||
This function is a possible cancellation point and therefore not
|
This function is a possible cancellation point and therefore not
|
||||||
marked with __THROW. */
|
marked with __THROW. */
|
||||||
extern char *gets (char *__s) __wur;
|
extern char *gets (char *__s) __wur __attribute_deprecated__;
|
||||||
#endif
|
#endif
|
||||||
__END_NAMESPACE_STD
|
__END_NAMESPACE_STD
|
||||||
|
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
/* Tests for gets.
|
/* Tests for gets.
|
||||||
Copyright (C) 2001 Free Software Foundation, Inc.
|
Copyright (C) 2001, 2011 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
Contributed by Ulrich Drepper <drepper@redhat.com>, 2001.
|
Contributed by Ulrich Drepper <drepper@redhat.com>, 2001.
|
||||||
|
|
||||||
@@ -21,6 +21,11 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
|
/* The <stdio.h> header does not include the declaration for gets
|
||||||
|
anymore when compiling with _GNU_SOURCE. Provide a copy here. */
|
||||||
|
extern char *gets (char *__s);
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
main (void)
|
main (void)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user