From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 83218 invoked by alias); 3 Mar 2015 15:49:09 -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 83145 invoked by uid 89); 3 Mar 2015 15:49:08 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: e06smtp14.uk.ibm.com Received: from e06smtp14.uk.ibm.com (HELO e06smtp14.uk.ibm.com) (195.75.94.110) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Tue, 03 Mar 2015 15:49:07 +0000 Received: from /spool/local by e06smtp14.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 3 Mar 2015 15:49:04 -0000 Received: from d06dlp01.portsmouth.uk.ibm.com (9.149.20.13) by e06smtp14.uk.ibm.com (192.168.101.144) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 3 Mar 2015 15:49:01 -0000 Received: from b06cxnps3075.portsmouth.uk.ibm.com (d06relay10.portsmouth.uk.ibm.com [9.149.109.195]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id 498A717D805D for ; Tue, 3 Mar 2015 15:49:20 +0000 (GMT) Received: from d06av08.portsmouth.uk.ibm.com (d06av08.portsmouth.uk.ibm.com [9.149.37.249]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t23Fn1bB10748248 for ; Tue, 3 Mar 2015 15:49:01 GMT Received: from d06av08.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av08.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t23Fn0GR030886 for ; Tue, 3 Mar 2015 08:49:01 -0700 Received: from br87z6lw.de.ibm.com (dyn-9-152-212-115.boeblingen.de.ibm.com [9.152.212.115]) by d06av08.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id t23Fn0RI030879; Tue, 3 Mar 2015 08:49:00 -0700 From: Andreas Arnez To: Gary Benson Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] New common function "startswith" References: <1425388224-8146-1-git-send-email-gbenson@redhat.com> Date: Tue, 03 Mar 2015 15:49:00 -0000 In-Reply-To: <1425388224-8146-1-git-send-email-gbenson@redhat.com> (Gary Benson's message of "Tue, 3 Mar 2015 13:10:24 +0000") Message-ID: <877fuyxes3.fsf@br87z6lw.de.ibm.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 15030315-0017-0000-0000-00000337B017 X-IsSubscribed: yes X-SW-Source: 2015-03/txt/msg00093.txt.bz2 On Tue, Mar 03 2015, Gary Benson wrote: > diff --git a/gdb/common/common-utils.c b/gdb/common/common-utils.c > index 2925dd5..5fb4af1 100644 > --- a/gdb/common/common-utils.c > +++ b/gdb/common/common-utils.c > @@ -151,3 +151,11 @@ savestring (const char *ptr, size_t len) > p[len] = 0; > return p; > } > + > +/* See common-utils.h. */ > + > +int > +startswith (const char *s1, const char *s2) > +{ > + return startswith (s1, s2); > +} > diff --git a/gdb/common/common-utils.h b/gdb/common/common-utils.h > index 60aa030..c887b6b 100644 > --- a/gdb/common/common-utils.h > +++ b/gdb/common/common-utils.h > @@ -68,4 +68,9 @@ char *savestring (const char *ptr, size_t len); > > extern char *safe_strerror (int); > > +/* Return nonzero if the first strlen(S2) bytes of S1 match S2, zero > + otherwise. */ > + > +extern int startswith (const char *s1, const char *s2); > + > #endif Hm, startswith() does not appear to be implemented in your patch. Maybe an extern inline definition in the header file was intended?