bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Suggested fix to mountlist.c: Define fuse.portal, devtmpfs and squashfs


From: Daniel Bonner
Subject: Suggested fix to mountlist.c: Define fuse.portal, devtmpfs and squashfs mounts as dummy
Date: Sat, 13 Feb 2021 12:40:02 +1100

Hi gnulib developers,
At present many gnulib users encounter this error:
Running 'df' as user (not root) causes results in output that includes
this error message:
"df: /run/user/1000/doc: Operation not permitted"
I would like to pass on to you a suggested fix:
@@ -164,7 +164,10 @@
 #define ME_DUMMY_0(Fs_name, Fs_type)            \
   (strcmp (Fs_type, "autofs") == 0              \
+   || strcmp (Fs_type, "devtmpfs") == 0         \
+   || strcmp (Fs_type, "fuse.portal") == 0      \
    || strcmp (Fs_type, "proc") == 0             \
+   || strcmp (Fs_type, "squashfs") == 0         \
    || strcmp (Fs_type, "subfs") == 0            \
    /* for Linux 2.6/3.x */                      \
    || strcmp (Fs_type, "debugfs") == 0          \
Julian Klode, from Ubuntu, deserves credit for this suggested fix. He
published a patch that has been included in the Ubuntu Hirsute 21.04
package: coreutils 8.32-4ubuntu2.  See
1. https://bugs.launchpad.net/ubuntu/+source/xdg-desktop-portal/+bug/19056232.
2. 
https://launchpadlibrarian.net/510003931/coreutils_8.32-4ubuntu1_8.32-4ubuntu2.diff.gz
I have cc'ed Julian in this email.
The patch addresses a problem that particularly affects gnulib users
with fuse.portal mounts, such as users who have installed Flatpak.
This is a significant problem for users who depend on df not returning
an error exit code in their scripts.  Julian's  bug report said:
"/run/user/1000/doc is a fuse.portal mount point, but statfs() return
EPERM, hence df produces an error message. Maybe statfs() is not
implemented, but it would be good to quieten this down (df even does
not allow me to ignore it, probably because it looks at statfs to find
out fs type, so my fs type ignoring doesn't work)."
This problem has also been reported on Fedora 32 here:
flatpak/xdg-desktop-portal#512
Kind regards,
Daniel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]