[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[hurd] 09/64: Fix recording complete path of passive relative translator
From: |
Samuel Thibault |
Subject: |
[hurd] 09/64: Fix recording complete path of passive relative translators |
Date: |
Wed, 10 Dec 2014 15:17:03 +0000 |
This is an automated email from the git hooks/post-receive script.
sthibault pushed a commit to branch upstream
in repository hurd.
commit 9a56d8f0803d40dacb92eb366b534bbbd5438096
Author: Samuel Thibault <address@hidden>
Date: Fri Nov 21 02:52:18 2014 +0100
Fix recording complete path of passive relative translators
* libnetfs/dir-lookup.c (netfs_S_dir_lookup): Prepend current path to
the relative path before recording the active translator.
---
libnetfs/dir-lookup.c | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/libnetfs/dir-lookup.c b/libnetfs/dir-lookup.c
index 99a8746..2d3da94 100644
--- a/libnetfs/dir-lookup.c
+++ b/libnetfs/dir-lookup.c
@@ -297,6 +297,7 @@ netfs_S_dir_lookup (struct protid *diruser,
if (register_translator)
{
char *translator_path = strdupa (relpath);
+ char *complete_path;
if (nextname != NULL)
{
/* This was not the last path component.
@@ -309,9 +310,17 @@ netfs_S_dir_lookup (struct protid *diruser,
translator_path[end - filename_start] = '\0';
}
+ if (diruser->po->path == NULL)
+ /* diruser is the root directory. */
+ complete_path = translator_path;
+ else
+ asprintf (&complete_path, "%s/%s", diruser->po->path,
translator_path);
+
error = fshelp_set_active_translator (&newpi->pi,
- translator_path,
+ complete_path,
np->transbox.active);
+ if (complete_path != translator_path)
+ free(complete_path);
if (error)
{
ports_port_deref (newpi);
--
Alioth's /usr/local/bin/git-commit-notice on
/srv/git.debian.org/git/pkg-hurd/hurd.git
- [hurd] branch upstream updated (e4a9a4d -> 4c7abe4), Samuel Thibault, 2014/12/10
- [hurd] 09/64: Fix recording complete path of passive relative translators,
Samuel Thibault <=
- [hurd] 10/64: Fix compiler warning, Samuel Thibault, 2014/12/10
- [hurd] 12/64: trans/mtab: avoid firmlink loops, Samuel Thibault, 2014/12/10
- [hurd] 15/64: startup: rename /hurd/init to /hurd/startup, Samuel Thibault, 2014/12/10
- [hurd] 11/64: Always canonicalize fstab entries with realpath, Samuel Thibault, 2014/12/10
- [hurd] 23/64: startup: also open `console' for reading, Samuel Thibault, 2014/12/10
- [hurd] 26/64: boot: drop obsolete device procedures, Samuel Thibault, 2014/12/10
- [hurd] 16/64: init: add a minimalist init program, Samuel Thibault, 2014/12/10
- [hurd] 22/64: proc: gracefully handle failure to increase priority, Samuel Thibault, 2014/12/10
- [hurd] 25/64: boot: remove unused function `boot_script_read_file', Samuel Thibault, 2014/12/10
- [hurd] 31/64: libdiskfs: fix fabrication of protid, Samuel Thibault, 2014/12/10