From: Stephen W. <st...@ke...> - 2007-07-26 18:21:10
|
Stephen Watson <Ste...@ul...> wrote: > rox...@li... wrote: > > So I thought I'd see what the Filer was seeing for the values... but > > when I rebuilt it I found that it wasn't even checking those symlinks > > and, indeed, they appear just fine. > > I've had a quick look after it happened to me. It appears there is a bug in diritem_restat() when handling relative symbolic links as mount_is_mounted() gets passed a relative path, in my case "../..". It then stats "../../.." as the parent which, when the filer is running from my home directory is a different device. > > If you've restarted the filer, it may be running from a different directory and the relative paths may be ending up elsewhere. Use pathdup() in diritem_restart(), not readlink_dup(), to ensure that we get the full pathname and not a path relative to the filer's working directory (Stephen Watson). diff --git a/ROX-Filer/src/diritem.c b/ROX-Filer/src/diritem.c index 869cff3..7a24391 100644 --- a/ROX-Filer/src/diritem.c +++ b/ROX-Filer/src/diritem.c @@ -118,7 +118,7 @@ void diritem_restat(const guchar *path, item->flags |= ITEM_FLAG_SYMLINK; - target_path = readlink_dup(path); + target_path = pathdup(path); } else { -- Stephen Watson http://www.kerofin.demon.co.uk/ If you read this on a mailing list, send any reply back to the list and not to me. Not even CC. "Bad dog!" "Affirmative!" |