From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-5.7 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS, SPF_PASS shortcircuit=no autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 23E5C1F4B4 for ; Thu, 31 Dec 2020 21:47:46 +0000 (UTC) Received: from localhost ([::1]:60102 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kv5nM-0006Xb-T7 for normalperson@yhbt.net; Thu, 31 Dec 2020 16:47:44 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:41208) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kv5nJ-0006XS-Rz for bug-gnulib@gnu.org; Thu, 31 Dec 2020 16:47:41 -0500 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:57948) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kv5nG-0001Pi-6q for bug-gnulib@gnu.org; Thu, 31 Dec 2020 16:47:41 -0500 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id C484216010E; Thu, 31 Dec 2020 13:47:34 -0800 (PST) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id eoelX8amjlRE; Thu, 31 Dec 2020 13:47:33 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id BD55316010F; Thu, 31 Dec 2020 13:47:33 -0800 (PST) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id plZgm-mbNRhO; Thu, 31 Dec 2020 13:47:33 -0800 (PST) Received: from [192.168.1.9] (cpe-23-243-218-95.socal.res.rr.com [23.243.218.95]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 8ECFC16010E; Thu, 31 Dec 2020 13:47:33 -0800 (PST) To: Adhemerval Zanella References: <20201230201507.2755086-1-adhemerval.zanella@linaro.org> <20201230201507.2755086-2-adhemerval.zanella@linaro.org> From: Paul Eggert Organization: UCLA Computer Science Department Subject: Re: [PATCH 2/5] posix: Sync glob code with gnulib Message-ID: Date: Thu, 31 Dec 2020 13:47:33 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.5.0 MIME-Version: 1.0 In-Reply-To: <20201230201507.2755086-2-adhemerval.zanella@linaro.org> Content-Type: multipart/mixed; boundary="------------985FC75F630DF48F2E896DC0" Content-Language: en-US Received-SPF: pass client-ip=131.179.128.68; envelope-from=eggert@cs.ucla.edu; helo=zimbra.cs.ucla.edu X-Spam_score_int: -75 X-Spam_score: -7.6 X-Spam_bar: ------- X-Spam_report: (-7.6 / 5.0 requ) BAYES_00=-1.9, NICE_REPLY_A=-3.399, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: bug-gnulib@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Gnulib discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: libc-alpha@sourceware.org, bug-gnulib@gnu.org Errors-To: bug-gnulib-bounces+normalperson=yhbt.net@gnu.org Sender: "bug-gnulib" This is a multi-part message in MIME format. --------------985FC75F630DF48F2E896DC0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable On 12/30/20 12:15 PM, Adhemerval Zanella wrote: > It sync with gnulib commit 43ee1a6bf and fixes and use-after-free > bug (gnulib commit 717766da8926e36). The main change over gnulib > is: >=20 > --- posix/glob.c > +++ lib/glob.c > @@ -59,6 +59,12 @@ > # define readdir(str) __readdir64 (str) > # define getpwnam_r(name, bufp, buf, len, res) \ > __getpwnam_r (name, bufp, buf, len, res) > +# ifndef __lstat64 > +# define __lstat64(fname, buf) __lxstat64 (_STAT_VER, fname, buf) > +# endif > +# ifndef __stat64 > +# define __stat64(fname, buf) __xstat64 (_STAT_VER, fname, buf) > +# endif > # define struct_stat64 struct stat64 > # define FLEXIBLE_ARRAY_MEMBER > # include Thanks, the code patch looks fine. You can now simplify its commit=20 message because I just now propagated the above fix into Gnulib, by=20 installing the attached patch into Gnulib. --------------985FC75F630DF48F2E896DC0 Content-Type: text/x-patch; charset=UTF-8; name="0001-glob-merge-proposed-glibc-changes.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="0001-glob-merge-proposed-glibc-changes.patch" =46rom 562592fc53384f9b9ecdd40577cc94c10c3f7eea Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Thu, 31 Dec 2020 09:05:13 -0800 Subject: [PATCH 1/2] glob: merge proposed glibc changes This merges the change proposed by Adhemerval Zanella in: https://sourceware.org/pipermail/libc-alpha/2020-December/121211.html * lib/glob.c (__lstat64, __stat64) [_LIBC]: Remove. --- ChangeLog | 7 +++++++ lib/glob.c | 6 ------ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7dd4ffdd6..5da7c043a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2020-12-31 Paul Eggert + + glob: merge proposed glibc changes + This merges the change proposed by Adhemerval Zanella in: + https://sourceware.org/pipermail/libc-alpha/2020-December/121211.html + * lib/glob.c (__lstat64, __stat64) [_LIBC]: Remove. + 2020-12-31 Bruno Haible =20 memalign: Work around Solaris bug. diff --git a/lib/glob.c b/lib/glob.c index 3c444d3b1..20239f780 100644 --- a/lib/glob.c +++ b/lib/glob.c @@ -59,12 +59,6 @@ # define readdir(str) __readdir64 (str) # define getpwnam_r(name, bufp, buf, len, res) \ __getpwnam_r (name, bufp, buf, len, res) -# ifndef __lstat64 -# define __lstat64(fname, buf) __lxstat64 (_STAT_VER, fname, buf) -# endif -# ifndef __stat64 -# define __stat64(fname, buf) __xstat64 (_STAT_VER, fname, buf) -# endif # define struct_stat64 struct stat64 # define FLEXIBLE_ARRAY_MEMBER # include --=20 2.27.0 --------------985FC75F630DF48F2E896DC0--