Closed gzetzsche closed 5 months ago
This was with the packages fusefs-bindfs-1.17.6_1
and fusefs-libs3-3.16.2
.
Strange. Did you find the cause?
Oh, I must have closed this issue by accident---there was no change with the problem described above.
I tested a bit more: getcwd()
actually returns NULL
and sets errno
to ENOENT
(No such file or directory).
This also happens with libfuse's example passthrough FS, so this looks like a FUSE bug, not a bindfs bug.
On FreeBSD (tested on 14.0), if you
bindfs
a directory where other filesystems are mounted below, thengetcwd
gives bogus results in those subdirectories. Example:Here,
a.out
is the following C program:The issue can also be reproduced without compiling a C program:
(but then it's not obvious that the problem lies in what
getcwd()
does. Sometimes,os.getcwd()
executes, but yields a string where the subdirectory is just replaced by.
.)The above situation occurs, e.g. when using
bindfs
to mount a tree of ZFS datasets, where the sub-datasets are mounted in subdirectories. Compared to FreeBSD's ownnullfs
,bindfs
has the advantage of crossing filesystem boundaries.