Commit 4be20458 authored by Samuel Thibault's avatar Samuel Thibault

hurd: fixes qt's file size query

  * debian/patches/hurd-i386/git-AT_EMPTY_PATH.diff: New patch.
parent 49767c9f
glibc (2.28-6) UNRELEASED; urgency=medium
* debian/patches/hurd-i386/git-AT_EMPTY_PATH.diff: New patch, fixes qt's
file size query.
-- Samuel Thibault <sthibault@debian.org> Tue, 22 Jan 2019 23:42:47 +0100
glibc (2.28-5) unstable; urgency=medium
[ Aurelien Jarno ]
......
commit ee4d79026da2c21c75cccd5795cb4357643f4f5c
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Tue Jan 22 23:38:36 2019 +0100
hurd: Support AT_EMPTY_PATH
* hurd/lookup-at.c (__file_name_lookup_at): When at_flags contains
AT_EMPTY_PATH, call __dir_lookup and __hurd_file_name_lookup_retry
directly instead of __hurd_file_name_lookup.
diff --git a/hurd/lookup-at.c b/hurd/lookup-at.c
index 813ebee8e5..3e6980f949 100644
--- a/hurd/lookup-at.c
+++ b/hurd/lookup-at.c
@@ -28,6 +28,9 @@ __file_name_lookup_at (int fd, int at_flags,
{
error_t err;
file_t result;
+ int empty = at_flags & AT_EMPTY_PATH;
+
+ at_flags &= ~AT_EMPTY_PATH;
err = __hurd_at_flags (&at_flags, &flags);
if (err)
@@ -36,6 +39,23 @@ __file_name_lookup_at (int fd, int at_flags,
if (fd == AT_FDCWD || file_name[0] == '/')
return __file_name_lookup (file_name, flags, mode);
+ if (empty != 0 && file_name[0] == '\0')
+ {
+ enum retry_type doretry;
+ char retryname[1024]; /* XXX string_t LOSES! */
+
+ err = HURD_DPORT_USE (fd, __dir_lookup (port, "", flags, mode,
+ &doretry, retryname,
+ &result));
+
+ if (! err)
+ err = __hurd_file_name_lookup_retry (&_hurd_ports_use, &__getdport,
+ NULL, doretry, retryname,
+ flags, mode, &result);
+
+ return err ? (__hurd_dfail (fd, err), MACH_PORT_NULL) : result;
+ }
+
file_t startdir;
error_t use_init_port (int which, error_t (*operate) (mach_port_t))
{
......@@ -93,6 +93,7 @@ hurd-i386/git-fcntl64.diff
hurd-i386/git-lockf-0.diff
hurd-i386/tg-WRLCK-upgrade.diff
hurd-i386/git-libpthread_setpshared.diff
hurd-i386/git-AT_EMPTY_PATH.diff
i386/local-biarch.diff
i386/unsubmitted-quiet-ldconfig.diff
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment