From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1791) id CF8403858406; Tue, 4 Oct 2022 12:55:22 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CF8403858406 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1664888122; bh=7z3vjfRnnAB+ofN51mIaB1O4x75Ezcuoy4SXsYDN5WM=; h=From:To:Subject:Date:From; b=lwjzU4yDTUtXPkw9fCxzvvUqdMq0gpuHCm6Ew8n/bFnGxKjGbAXftJyuE9PYbWIX3 ccTtiaoTETtxyRIrqFlLGey638VSdcFbKCFSTdH2sz8b2+r95TXFs46ZlfSX65A+8Z FSH76woZRWA03ZyjxZA052G68AqG6TKTkJQEybS4= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Adhemerval Zanella To: glibc-cvs@sourceware.org Subject: [glibc/azanella/clang] stdlib: DIAG_IGNORE_NEEDS_COMMENT setenv.c X-Act-Checkin: glibc X-Git-Author: Adhemerval Zanella X-Git-Refname: refs/heads/azanella/clang X-Git-Oldrev: fef612a18315ff9bf1598c4b768e3d382418e37e X-Git-Newrev: f3de9de2b43d5e0f69036eae77f8508962a48903 Message-Id: <20221004125522.CF8403858406@sourceware.org> Date: Tue, 4 Oct 2022 12:55:22 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=f3de9de2b43d5e0f69036eae77f8508962a48903 commit f3de9de2b43d5e0f69036eae77f8508962a48903 Author: Adhemerval Zanella Date: Tue Mar 8 17:37:11 2022 -0300 stdlib: DIAG_IGNORE_NEEDS_COMMENT setenv.c Checked on x86_64-linux-gnu. Diff: --- stdlib/setenv.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/stdlib/setenv.c b/stdlib/setenv.c index 2176cbac31..2add8bfb41 100644 --- a/stdlib/setenv.c +++ b/stdlib/setenv.c @@ -19,12 +19,14 @@ # include #endif +#if _LIBC +# include /* Pacify GCC; see the commentary about VALLEN below. This is needed at least through GCC 4.9.2. Pacify GCC for the entire file, as there seems to be no way to pacify GCC selectively, only for the - place where it's needed. Do not use DIAG_IGNORE_NEEDS_COMMENT - here, as it's not defined yet. */ -#pragma GCC diagnostic ignored "-Wmaybe-uninitialized" + place where it's needed. */ +DIAG_IGNORE_NEEDS_COMMENT (4.9, "-Wmaybe-uninitialized"); +#endif #include #if !_LIBC