unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* [hurd,commited] hurd: Fix fdopendir checking for directory type
@ 2020-05-28 10:18 Samuel Thibault
  0 siblings, 0 replies; only message in thread
From: Samuel Thibault @ 2020-05-28 10:18 UTC (permalink / raw)
  To: libc-alpha; +Cc: commit-hurd

* sysdeps/mach/hurd/fdopendir.c (__fdopendir): Lookup "./" instead of
"/" that would designate the root of the filesystem.
---
 sysdeps/mach/hurd/fdopendir.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sysdeps/mach/hurd/fdopendir.c b/sysdeps/mach/hurd/fdopendir.c
index f15801f141..0583cdca0f 100644
--- a/sysdeps/mach/hurd/fdopendir.c
+++ b/sysdeps/mach/hurd/fdopendir.c
@@ -39,7 +39,7 @@ __fdopendir (int fd)
   /* Ensure that it's a directory.  */
   error_t err = HURD_FD_PORT_USE
     (d, ({
-	file_t dir = __file_name_lookup_under (port, "/",
+	file_t dir = __file_name_lookup_under (port, "./",
 					       O_DIRECTORY | O_NOTRANS, 0);;
 	if (dir != MACH_PORT_NULL)
 	  __mach_port_deallocate (__mach_task_self (), dir);
-- 
2.26.2


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2020-05-28 10:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-28 10:18 [hurd,commited] hurd: Fix fdopendir checking for directory type Samuel Thibault

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).