diff options
| author | Karel Zak <kzak@redhat.com> | 2025-09-11 10:47:27 +0200 |
|---|---|---|
| committer | Karel Zak <kzak@redhat.com> | 2025-09-11 10:47:27 +0200 |
| commit | b1f8b5740d81d813a2ea9ae1db8f059e5bee3b60 (patch) | |
| tree | 8153df7353c8a230152b2fa4a7d6694941dc924b | |
| parent | 242736808ad5c9e1e3992f0a1076df2846773dd5 (diff) | |
| parent | 8a7bc1ab00d91e8a17ca8cb2907ca3c2a73381dd (diff) | |
| download | util-linux-b1f8b5740d81d813a2ea9ae1db8f059e5bee3b60.tar.gz | |
Merge branch 'PR/libmount-fsconfig-nofail' of https://github.com/karelzak/util-linux-work
* 'PR/libmount-fsconfig-nofail' of https://github.com/karelzak/util-linux-work:
libmount: don't report fsconfig errors with "nofail"
| -rw-r--r-- | libmount/src/context_mount.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libmount/src/context_mount.c b/libmount/src/context_mount.c index 9a1832550c..04734b73cd 100644 --- a/libmount/src/context_mount.c +++ b/libmount/src/context_mount.c @@ -1662,6 +1662,12 @@ int mnt_context_get_mount_excode( /* Error with already generated messages (by kernel or libmount) */ if (buf && mnt_context_get_nmesgs(cxt, 'e')) { + if (syserr == ENOENT + && uflags & MNT_MS_NOFAIL + && cxt->syscall_name && strcmp(cxt->syscall_name, "fsconfig") == 0 + && src && !mnt_is_path(src)) + return MNT_EX_SUCCESS; + if (cxt->syscall_name) { size_t len = snprintf(buf, bufsz, _("%s() failed: "), |
