From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16671 invoked by alias); 10 Jan 2012 22:25:03 -0000 Received: (qmail 16615 invoked by uid 22791); 10 Jan 2012 22:25:01 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 10 Jan 2012 22:24:44 +0000 From: "vries at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/51785] gets not anymore declared Date: Tue, 10 Jan 2012 22:25:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: vries at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: CC Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-01/txt/msg01128.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51785 vries at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |vries at gcc dot gnu.org --- Comment #2 from vries at gcc dot gnu.org 2012-01-10 22:24:10 UTC --- (In reply to comment #1) > I thought this was fixed in glibc: > http://sourceware.org/bugzilla/show_bug.cgi?id=13566 > ? AFAIU GLIBC BZ #13528 was fixed, but there is a new checkin from Ulrich which breaks libstdc++ build in a similar way: ... $ git show c3a87236702cb73be1dada3438bbd3c3934e83f8 commit c3a87236702cb73be1dada3438bbd3c3934e83f8 Author: Ulrich Drepper Date: Sat Jan 7 10:41:00 2012 -0500 Do not declare gets in _GNU_SOURCE mode at all diff --git a/ChangeLog b/ChangeLog index 8f9558c..f089e19 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ 2012-01-07 Ulrich Drepper + * libio/stdio.h: Do not declare gets at all for _GNU_SOURCE. + * elf/tst-unique3.cc: Add explicit declaration of gets. * elf/tst-unique3lib.cc: Likewise. * elf/tst-unique3lib2.cc: Likewise. diff --git a/libio/stdio.h b/libio/stdio.h index d9cb573..28c98e9 100644 --- a/libio/stdio.h +++ b/libio/stdio.h @@ -629,7 +629,7 @@ extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream) __wur; #if !defined __USE_ISOC11 \ - || (defined __cplusplus && __cplusplus <= 201103L) + || (defined __cplusplus && __cplusplus <= 201103L && !defined __USE_GNU) /* Get a newline-terminated string from stdin, removing the newline. DO NOT USE THIS FUNCTION!! There is no limit on how much it will read. ...