* Mon Jan 23 2012 Ian Kent <knt@redhat.com> - 1:5.0.6-9

- add correct patch for "fix improve mount location error reporting".
- add correct patch for "fix fix wait for master source mutex".
This commit is contained in:
Ian Kent 2012-01-23 09:05:51 +08:00
parent 4c8499d9fc
commit 8963ad3659
3 changed files with 84 additions and 3 deletions

View File

@ -0,0 +1,28 @@
autofs-5.0.6 - fix fix wait for master source mutex
From: Ian Kent <raven@themaw.net>
The "wait for master source mutex" change wait for a busy read/write
mutex to become available instead of failing. The s390x architecture
is slower than the Intel architectures and the time allowed to wait
can be too short leading to a failure anyway.
This patch increases the maximum wait from 1 second to 5 seconds to
avoid false positive fails.
---
lib/master.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- autofs-5.0.6.orig/lib/master.c
+++ autofs-5.0.6/lib/master.c
@@ -552,7 +552,7 @@ void master_source_writelock(struct mast
void master_source_readlock(struct master_mapent *entry)
{
- int retries = 5; /* 1 second maximum */
+ int retries = 25; /* 5 second maximum */
int status;
while (retries--) {

View File

@ -0,0 +1,49 @@
autofs-5.0.6 - fix improve mount location error reporting
From: Ian Kent <raven@themaw.net>
The validate_location() function is meant to check for a small subset
of map location errors only but the "improve mount location error
reporting" patch inverted a logic test which has made the scope of
the test greater causing false positive fails. So add a check for
those special cases and return success instead.
---
CHANGELOG | 1 +
modules/parse_sun.c | 14 ++++++++++++++
2 files changed, 15 insertions(+)
--- autofs-5.0.6.orig/CHANGELOG
+++ autofs-5.0.6/CHANGELOG
@@ -19,6 +19,7 @@
- add piddir to configure.
- add systemd unit support.
- remove empty command line arguments (passed by systemd).
+- fix improve mount location error reporting.
28/06/2011 autofs-5.0.6
-----------------------
--- autofs-5.0.6.orig/modules/parse_sun.c
+++ autofs-5.0.6/modules/parse_sun.c
@@ -868,6 +868,20 @@ static int validate_location(unsigned in
* have ":", "[" and "]".
*/
if (!check_colon(ptr)) {
+ char *esc;
+ /*
+ * Don't forget cases where a colon is present but
+ * not followed by a "/" or, if there is no colon at
+ * all, we don't know if it is actually invalid since
+ * it may be a map name by itself, for example.
+ */
+ if (!strchr(ptr, ':') ||
+ ((esc = strchr(ptr, '\\')) && *(esc + 1) == ':') ||
+ !strncmp(ptr, "file:", 5) || !strncmp(ptr, "yp:", 3) ||
+ !strncmp(ptr, "nis:", 4) || !strncmp(ptr, "nisplus:", 8) ||
+ !strncmp(ptr, "ldap:", 5) || !strncmp(ptr, "ldaps:", 6) ||
+ !strncmp(ptr, "dir:", 4))
+ return 1;
error(logopt,
"expected colon delimeter not found in location %s",
loc);

View File

@ -8,7 +8,7 @@
Summary: A tool for automatically mounting and unmounting filesystems Summary: A tool for automatically mounting and unmounting filesystems
Name: autofs Name: autofs
Version: 5.0.6 Version: 5.0.6
Release: 8%{?dist} Release: 9%{?dist}
Epoch: 1 Epoch: 1
License: GPLv2+ License: GPLv2+
Group: System Environment/Daemons Group: System Environment/Daemons
@ -34,8 +34,8 @@ Patch18: autofs-5.0.6-add-piddir-to-configure.patch
Patch19: autofs-5.0.6-add-systemd-unit-support.patch Patch19: autofs-5.0.6-add-systemd-unit-support.patch
Patch20: autofs-5.0.6-fix-MNT_DETACH-define.patch Patch20: autofs-5.0.6-fix-MNT_DETACH-define.patch
Patch21: autofs-5.0.6-remove-empty-command-line-arguments.patch Patch21: autofs-5.0.6-remove-empty-command-line-arguments.patch
Patch22: autofs-5.0.6-fix-wait-for-master-source-mutex.patch Patch22: autofs-5.0.6-fix-fix-wait-for-master-source-mutex.patch
Patch23: autofs-5.0.6-improve-mount-location-error-reporting.patch Patch23: autofs-5.0.6-fix-improve-mount-location-error-reporting.patch
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%if %{with_systemd} %if %{with_systemd}
BuildRequires: systemd-units BuildRequires: systemd-units
@ -197,6 +197,10 @@ fi
%dir /etc/auto.master.d %dir /etc/auto.master.d
%changelog %changelog
* Mon Jan 23 2012 Ian Kent <knt@redhat.com> - 1:5.0.6-9
- add correct patch for "fix improve mount location error reporting".
- add correct patch for "fix fix wait for master source mutex".
* Mon Jan 23 2012 Ian Kent <knt@redhat.com> - 1:5.0.6-8 * Mon Jan 23 2012 Ian Kent <knt@redhat.com> - 1:5.0.6-8
- fix fix wait for master source mutex. - fix fix wait for master source mutex.
- fix improve mount location error reporting (bz783496). - fix improve mount location error reporting (bz783496).