- add additional fix for bug 1970478.

This commit is contained in:
Ian Kent 2021-06-17 14:06:03 +08:00
parent c17a252d35
commit 575e53adc4
2 changed files with 44 additions and 1 deletions

View File

@ -0,0 +1,38 @@
autofs-5.1.7 - fix nonstrict offset mount fail handling
From: Ian Kent <raven@themaw.net>
If a triggered offset mount fails automount is no honouring nonstrict
mount failure.
Signed-off-by: Ian Kent <raven@themaw.net>
---
CHANGELOG | 1 +
modules/parse_sun.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/CHANGELOG b/CHANGELOG
index f5f0da76..ecffa933 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -77,6 +77,7 @@
- fix hosts map offset order.
- fix direct mount deadlock.
- add missing description of null map option.
+- fix nonstrict offset mount fail handling.
25/01/2021 autofs-5.1.7
- make bind mounts propagation slave by default.
diff --git a/modules/parse_sun.c b/modules/parse_sun.c
index 12844a30..cdf515c6 100644
--- a/modules/parse_sun.c
+++ b/modules/parse_sun.c
@@ -1181,7 +1181,7 @@ static int mount_subtree(struct autofs_point *ap, struct mapent_cache *mc,
* offsets to be mounted.
*/
rv = sun_mount(ap, name, name, namelen, loc, loclen, options, ctxt);
- if (rv == 0) {
+ if (rv <= 0) {
ret = tree_mapent_mount_offsets(me, 1);
if (!ret) {
tree_mapent_cleanup_offsets(me);

View File

@ -12,7 +12,7 @@
Summary: A tool for automatically mounting and unmounting filesystems
Name: autofs
Version: 5.1.7
Release: 15%{?dist}
Release: 16%{?dist}
Epoch: 1
License: GPLv2+
Source: https://www.kernel.org/pub/linux/daemons/autofs/v5/autofs-%{version}.tar.gz
@ -95,6 +95,7 @@ Patch75: autofs-5.1.7-eliminate-redundant-cache-lookup-in-tree_mapent_add_node.p
Patch76: autofs-5.1.7-fix-hosts-map-offset-order.patch
Patch77: autofs-5.1.7-fix-direct-mount-deadlock.patch
Patch78: autofs-5.1.7-add-missing-description-of-null-map-option.patch
Patch79: autofs-5.1.7-fix-nonstrict-offset-mount-fail-handling.patch
%if %{with_systemd}
BuildRequires: systemd-units
@ -237,6 +238,7 @@ echo %{version}-%{release} > .version
%patch76 -p1
%patch77 -p1
%patch78 -p1
%patch79 -p1
%build
LDFLAGS=-Wl,-z,now
@ -345,6 +347,9 @@ fi
%dir /etc/auto.master.d
%changelog
* Thu Jun 17 2021 Ian Kent <ikent@redhat.com> - 1:5.1.7-16
- fix nonstrict offset mount fail handling.
* Tue Jun 15 2021 Ian Kent <ikent@redhat.com> - 1:5.1.7-15
- fix amd hosts mount expire.
- fix offset entries order.