public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Paul Eggert <eggert@cs.ucla.edu>
To: DJ Delorie <dj@redhat.com>
Cc: libc-alpha@sourceware.org, Gnulib bugs <bug-gnulib@gnu.org>
Subject: Re: posix/glob.c: update from gnulib
Date: Wed, 30 Mar 2022 16:45:34 -0700	[thread overview]
Message-ID: <3afdb359-2b7a-78b4-e60f-159d312a390b@cs.ucla.edu> (raw)
In-Reply-To: <038e38d7-59f3-527b-b6ae-f9b7d8ccdb06@cs.ucla.edu>

[-- Attachment #1: Type: text/plain, Size: 183 bytes --]

On 3/30/22 16:40, Paul Eggert wrote:
> 
> I updated Gnulib to reflect this change; see first attached patch.

Oops, forgot to attach that patch. Here it is. Also cc'ing to bug-gnulib.

[-- Attachment #2: 0001-glob-sync-better-with-glibc.patch --]
[-- Type: text/x-patch, Size: 1270 bytes --]

From 8fa9898afa5ee3da8f5d5a4797f98ae62b12d427 Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Wed, 30 Mar 2022 16:29:11 -0700
Subject: [PATCH] glob: sync better with glibc

* lib/glob.c (dirfd) [_LIBC]: Use #undef instead of #ifdef.
Problem reported by DJ Delorie.
---
 ChangeLog  | 6 ++++++
 lib/glob.c | 5 ++---
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 7ea4f7797b..0f88fceed0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2022-03-30  Paul Eggert  <eggert@cs.ucla.edu>
+
+	glob: sync better with glibc
+	* lib/glob.c (dirfd) [_LIBC]: Use #undef instead of #ifdef.
+	Problem reported by DJ Delorie.
+
 2022-03-23  Paul Eggert  <eggert@cs.ucla.edu>
 
 	glob: test for glibc bug 25659
diff --git a/lib/glob.c b/lib/glob.c
index 52c79b4cd8..f6993a3706 100644
--- a/lib/glob.c
+++ b/lib/glob.c
@@ -57,9 +57,8 @@
 # define sysconf(id) __sysconf (id)
 # define closedir(dir) __closedir (dir)
 # define opendir(name) __opendir (name)
-# ifndef dirfd
-#  define dirfd(str) __dirfd (str)
-# endif
+# undef dirfd
+# define dirfd(str) __dirfd (str)
 # define readdir(str) __readdir64 (str)
 # define getpwnam_r(name, bufp, buf, len, res) \
     __getpwnam_r (name, bufp, buf, len, res)
-- 
2.35.1


  reply	other threads:[~2022-03-30 23:45 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-30 21:55 DJ Delorie
2022-03-30 23:40 ` Paul Eggert
2022-03-30 23:45   ` Paul Eggert [this message]
2022-03-30 23:54   ` DJ Delorie
2022-03-31 10:56 ` Adhemerval Zanella
2022-03-31 17:38   ` DJ Delorie
2022-03-31 17:44     ` Adhemerval Zanella
2022-03-31 19:29       ` DJ Delorie
2022-03-31 19:38         ` Adhemerval Zanella
2022-03-31 20:00       ` [v2] " DJ Delorie
2022-04-01  1:55         ` Paul Eggert
2022-04-04 21:25           ` Carlos O'Donell
2022-04-14 23:40             ` [v3] " DJ Delorie
2022-04-27 21:16               ` Carlos O'Donell
2022-04-27 21:21                 ` DJ Delorie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3afdb359-2b7a-78b4-e60f-159d312a390b@cs.ucla.edu \
    --to=eggert@cs.ucla.edu \
    --cc=bug-gnulib@gnu.org \
    --cc=dj@redhat.com \
    --cc=libc-alpha@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).