From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23245 invoked by alias); 1 Nov 2019 15:21:14 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 23237 invoked by uid 89); 1 Nov 2019 15:21:14 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham version=3.3.1 spammy= X-HELO: mx1.osci.io Received: from polly.osci.io (HELO mx1.osci.io) (8.43.85.229) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 01 Nov 2019 15:21:13 +0000 Received: by mx1.osci.io (Postfix, from userid 994) id 8BFBA20172; Fri, 1 Nov 2019 11:21:11 -0400 (EDT) Received: from gnutoolchain-gerrit.osci.io (gnutoolchain-gerrit.osci.io [IPv6:2620:52:3:1:5054:ff:fe06:16ca]) by mx1.osci.io (Postfix) with ESMTP id 575A4203A6; Fri, 1 Nov 2019 11:21:07 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by gnutoolchain-gerrit.osci.io (Postfix) with ESMTP id 397B620AF6; Fri, 1 Nov 2019 11:21:07 -0400 (EDT) X-Gerrit-PatchSet: 3 Date: Fri, 01 Nov 2019 15:21:00 -0000 From: "Hannes Domani (Code Review)" To: Christian Biesinger , gdb-patches@sourceware.org Cc: Simon Marchi Auto-Submitted: auto-generated X-Gerrit-MessageType: comment Subject: [review v3] Use strerror_r in safe_strerror if available X-Gerrit-Change-Id: I81048fbaf148035c221c528727f7efe58ba528eb X-Gerrit-Change-Number: 474 X-Gerrit-ChangeURL: X-Gerrit-Commit: b231e86ac9608056ea837e24d42a878927f5787a In-Reply-To: References: X-Gerrit-Comment-Date: Fri, 1 Nov 2019 11:21:07 -0400 Reply-To: gnutoolchain-gerrit@osci.io MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Disposition: inline User-Agent: Gerrit/3.0.3-75-g9005159e5d Content-Type: text/plain; charset=UTF-8 Message-Id: <20191101152107.397B620AF6@gnutoolchain-gerrit.osci.io> X-SW-Source: 2019-11/txt/msg00031.txt.bz2 Hannes Domani has posted comments on this change. Change URL: https://gnutoolchain-gerrit.osci.io/r/c/binutils-gdb/+/474 ...................................................................... Patch Set 3: (1 comment) > Patch Set 1: > > (2 comments) New build failure for windows. https://gnutoolchain-gerrit.osci.io/r/c/binutils-gdb/+/474/3/gdb/gdbsupport/common-utils.h File gdb/gdbsupport/common-utils.h: https://gnutoolchain-gerrit.osci.io/r/c/binutils-gdb/+/474/3/gdb/gdbsupport/common-utils.h@113 PS3, Line 113: 108 | 109 | /* The strerror() function can return NULL for errno values that are 110 | out of range. Provide a "safe" version that always returns a 111 | printable string. This version is also thread-safe. */ 112 | 113 > extern const char *safe_strerror (int); 114 | 115 | /* Return true if the start of STRING matches PATTERN, false otherwise. */ 116 | 117 | static inline bool 118 | startswith (const char *string, const char *pattern) The windows build now fails, because safe_strerror() of mingw-strerror.c doesn't match this prototype anymore: C:/src/repos/binutils-gdb.git/gdb/gdbsupport/mingw-strerror.c:32:1: error: ambiguating new declaration of 'char* safe_strerror(int)' 32 | safe_strerror (int errnum) | ^~~~~~~~~~~~~ In file included from C:/src/repos/binutils-gdb.git/gdb/gdbsupport/common-defs.h:122, from C:/src/repos/binutils-gdb.git/gdb/gdbsupport/mingw-strerror.c:20: C:/src/repos/binutils-gdb.git/gdb/gdbsupport/common-utils.h:113:20: note: old declaration 'const char* safe_strerror(int)' 113 | extern const char *safe_strerror (int); | ^~~~~~~~~~~~~ -- Gerrit-Project: binutils-gdb Gerrit-Branch: master Gerrit-Change-Id: I81048fbaf148035c221c528727f7efe58ba528eb Gerrit-Change-Number: 474 Gerrit-PatchSet: 3 Gerrit-Owner: Christian Biesinger Gerrit-Reviewer: Simon Marchi Gerrit-CC: Hannes Domani Gerrit-Comment-Date: Fri, 01 Nov 2019 15:21:07 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Gerrit-MessageType: comment