Allow unknown root directory.
authorSamuel Thibault <samuel.thibault@ens-lyon.org>
Wed, 1 May 2019 17:24:19 +0000 (18:24 +0100)
committerAurelien Jarno <aurel32@debian.org>
Wed, 1 May 2019 17:24:19 +0000 (18:24 +0100)
commit86716e5063c2fa987d40fd5d4a13f02d84fe9b7c
treed4488c2cb12f290e7c910e1366528318f2deb605
parentfa7c806dd4f0ea2c7b7d287b31d3a36738d2c9fa
Allow unknown root directory.

To be efficient, the remap translator simply returns ports from the underlying
filesystem, and thus the root directory found through browsing '..' is the
underlying root, not the remap root. This should not be a reason for getcwd to
fail.

* sysdeps/mach/hurd/getcwd.c (_hurd_canonicalize_directory_name_internal): Do
not remove the heading slash if we got an unknown root directory.
(__getcwd): Do not fail with EGRATUITOUS if we got an unknown root directory.

Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Gbp-Pq: Topic hurd-i386
Gbp-Pq: Name tg-remap_getcwd.diff
sysdeps/mach/hurd/getcwd.c