]> Savannah Git Hosting - gnulib.git/commitdiff
mountlist: Consider AFS filesystems as remote
authorMarc Dionne <marc.dionne@auristor.com>
Wed, 5 Feb 2020 21:35:12 +0000 (13:35 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Wed, 5 Feb 2020 21:46:51 +0000 (13:46 -0800)
df --local relies on the ME_REMOTE macro to determine if a given
mount entry should be considered "local".  There is special logic
for nfs and smb/cifs mounts, but /afs as mounted by OpenAFS, the
kernel's kafs module or AuriStorFS is treated as a local mount.
* lib/mountlist.c (ME_REMOTE): Treat mounts of type 'afs'
(OpenAFS, kernel kafs) and 'auristorfs' (AuriStorFS) as remote.

Copyright-paperwork-exempt: yes

ChangeLog
lib/mountlist.c

index e44dcb9a17dbd0b0e3dca9473fafa9b722e0e76b..99e0c2e9e015b042ce79ff1fec26e2610a2222d7 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2020-02-05  Marc Dionne  <marc.dionne@auristor.com>  (tiny change)
+
+       mountlist: Consider AFS filesystems as remote
+       df --local relies on the ME_REMOTE macro to determine if a given
+       mount entry should be considered "local".  There is special logic
+       for nfs and smb/cifs mounts, but /afs as mounted by OpenAFS, the
+       kernel's kafs module or AuriStorFS is treated as a local mount.
+       * lib/mountlist.c (ME_REMOTE): Treat mounts of type 'afs'
+       (OpenAFS, kernel kafs) and 'auristorfs' (AuriStorFS) as remote.
+
 2020-02-04  Paul Eggert  <eggert@cs.ucla.edu>
 
        Port _Noreturn to older Clang
index 61063ce91cf92bce8cb72839b6a09e80055e7b1d..255e350e0b56c3c4089d5e41d4acd9ecd3bb6ea7 100644 (file)
@@ -221,6 +221,7 @@ me_remote (char const *fs_name, char const *fs_type _GL_UNUSED)
 #ifndef ME_REMOTE
 /* A file system is "remote" if its Fs_name contains a ':'
    or if (it is of type (smbfs or cifs) and its Fs_name starts with '//')
+   or if it is of type (afs or auristorfs)
    or Fs_name is equal to "-hosts" (used by autofs to mount remote fs).  */
 # define ME_REMOTE(Fs_name, Fs_type)            \
     (strchr (Fs_name, ':') != NULL              \
@@ -228,6 +229,8 @@ me_remote (char const *fs_name, char const *fs_type _GL_UNUSED)
          && (Fs_name)[1] == '/'                 \
          && (strcmp (Fs_type, "smbfs") == 0     \
              || strcmp (Fs_type, "cifs") == 0)) \
+     || strcmp (Fs_type, "afs") == 0            \
+     || strcmp (Fs_type, "auristorfs") == 0     \
      || (strcmp("-hosts", Fs_name) == 0))
 #endif