diff --git a/autofs-5.0.7-fix-a-couple-of-compiler-warnings.patch b/autofs-5.0.7-fix-a-couple-of-compiler-warnings.patch new file mode 100644 index 0000000..d1703d3 --- /dev/null +++ b/autofs-5.0.7-fix-a-couple-of-compiler-warnings.patch @@ -0,0 +1,51 @@ +autofs-5.0.7 - fix a couple of compiler warnings + +From: Ian Kent + +Quiet a couple of ompiler warnings by making intention explicit using brackets. +--- + CHANGELOG | 1 + + modules/mount_bind.c | 2 +- + modules/mount_nfs.c | 4 ++-- + 3 files changed, 4 insertions(+), 3 deletions(-) + +diff --git a/CHANGELOG b/CHANGELOG +index 37eac72..7749f01 100644 +--- a/CHANGELOG ++++ b/CHANGELOG +@@ -54,6 +54,7 @@ + - misc man page fixes. + - fix add null check in parse_server_string(). + - don't override LDFLAGS in make rules. ++- fix a couple of compiler warnings. + + 25/07/2012 autofs-5.0.7 + ======================= +diff --git a/modules/mount_bind.c b/modules/mount_bind.c +index 61a773c..2b70104 100644 +--- a/modules/mount_bind.c ++++ b/modules/mount_bind.c +@@ -208,7 +208,7 @@ int mount_mount(struct autofs_point *ap, const char *root, const char *name, int + MODPREFIX + "failed to create local mount %s -> %s", + fullpath, what); +- if (ap->flags & MOUNT_FLAG_GHOST && !status) ++ if ((ap->flags & MOUNT_FLAG_GHOST) && !status) + if (mkdir_path(fullpath, 0555) && errno != EEXIST) { + char *estr = strerror_r(errno, buf, MAX_ERR_BUF); + error(ap->logopt, +diff --git a/modules/mount_nfs.c b/modules/mount_nfs.c +index 3d2ccea..adf2002 100644 +--- a/modules/mount_nfs.c ++++ b/modules/mount_nfs.c +@@ -202,8 +202,8 @@ int mount_mount(struct autofs_point *ap, const char *root, const char *name, int + */ + if ((hosts && !hosts->next) && + mount_default_proto == 4 && +- vers & NFS_VERS_MASK != 0 && +- vers & NFS4_VERS_MASK != 0) { ++ (vers & NFS_VERS_MASK) != 0 && ++ (vers & NFS4_VERS_MASK) != 0) { + unsigned int v4_probe_ok = 0; + struct host *tmp = new_host(hosts->name, + hosts->addr, hosts->addr_len, diff --git a/autofs.spec b/autofs.spec index 96dc850..9b6b43d 100644 --- a/autofs.spec +++ b/autofs.spec @@ -8,7 +8,7 @@ Summary: A tool for automatically mounting and unmounting filesystems Name: autofs Version: 5.0.7 -Release: 26%{?dist} +Release: 27%{?dist} Epoch: 1 License: GPLv2+ Group: System Environment/Daemons @@ -97,6 +97,7 @@ Patch81: autofs-5.0.7-fix-add-null-check-in-parse_server_string.patch Patch82: autofs-5.0.7-check-for-protocol-option.patch Patch83: autofs-5.0.7-use-ulimit-max-open-files-if-greater-than-internal-maximum.patch Patch84: autofs-5.0.7-dont-override-LDFLAGS-in-make-rules.patch +Patch85: autofs-5.0.7-fix-a-couple-of-compiler-warnings.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) %if %{with_systemd} BuildRequires: systemd-units @@ -238,6 +239,7 @@ echo %{version}-%{release} > .version %patch82 -p1 %patch83 -p1 %patch84 -p1 +%patch85 -p1 %build LDFLAGS=-Wl,-z,now @@ -329,6 +331,9 @@ fi %dir /etc/auto.master.d %changelog +* Sat Jul 13 2013 Ian Kent - 1:5.0.7-27 +- fix a couple of compiler warnings. + * Fri Jul 12 2013 Ian Kent - 1:5.0.7-26 - link with full reloc options.