thanks for opening the bug, it is indeed a result of the 0014-Don-t-compare-source-when-checking-if-it-s-already-m.patch.
As far as I understand polydirs are implemented as mount overlays and so /data2 in your example is a mount point already.
You can test this with this example using the same functions as libpam-mount:
It should list /data2 as a target if run as the user with the polydir.
As far as I understand, mounting something on top of the polydir would hide the polydir.
Hi Evan,
thanks for opening the bug, it is indeed a result of the 0014-Don- t-compare- source- when-checking- if-it-s- already- m.patch.
As far as I understand polydirs are implemented as mount overlays and so /data2 in your example is a mount point already.
You can test this with this example using the same functions as libpam-mount:
// sudo apt install gcc libmount-dev; cc -o lsmount lsmount.c -lmount; ./lsmount
#include <libmount/ libmount. h>
int main()
{
struct libmnt_context *ctx;
struct libmnt_table *table;
struct libmnt_iter *iter;
struct libmnt_fs *fs;
ctx = mnt_new_context(); get_mtab( ctx, &table) != 0) iter(MNT_ ITER_BACKWARD) ;
if (ctx == NULL)
return -1;
if (mnt_context_
goto out;
iter = mnt_new_
if (iter == NULL)
goto out;
while (mnt_table_ next_fs( table, iter, &fs) == 0) "source: \t%s target: %s\n", mnt_fs_ get_source( fs), mnt_fs_ get_target( fs)); context( ctx);
printf(
out:
mnt_free_
return 0;
}
It should list /data2 as a target if run as the user with the polydir.
As far as I understand, mounting something on top of the polydir would hide the polydir.
Can you give some more background of your setup?