%changelog

Thu Mar 8 2007 Ian Kent <ikent@redhat.com> - 5.0.1-4
- fixed numeric export match (bz 231188).
This commit is contained in:
ikent 2007-03-08 03:41:50 +00:00
parent 0e30ea1f6d
commit f1ee4e6350
2 changed files with 37 additions and 1 deletions

View File

@ -0,0 +1,31 @@
diff --git a/lib/rpc_subs.c b/lib/rpc_subs.c
index 2c5b5d5..5151a1e 100644
--- a/lib/rpc_subs.c
+++ b/lib/rpc_subs.c
@@ -1072,18 +1072,23 @@ static char *inet_fill_net(const char *net_num, char *net)
if (strlen(net_num) > INET_ADDRSTRLEN)
return NULL;
+ if (!isdigit(*net_num))
+ return NULL;
+
*net = '\0';
strcpy(net, net_num);
np = net;
- while (*np) {
- if (*np++ == '.') {
+ while (*np++) {
+ if (*np == '.') {
+ np++;
dots--;
if (!*np && dots)
strcat(net, "0");
+ continue;
}
- if (!isdigit(*np) || dots < 0) {
+ if ((*np && !isdigit(*np)) || dots < 0) {
*net = '\0';
return NULL;
}

View File

@ -4,7 +4,7 @@
Summary: A tool for automatically mounting and unmounting filesystems
Name: autofs
Version: 5.0.1
Release: 3
Release: 4
Epoch: 1
License: GPL
Group: System Environment/Daemons
@ -15,6 +15,7 @@ Patch2: autofs-5.0.1-hosts-simple-fail.patch
Patch3: autofs-5.0.1-export-check-network-fix-2.patch
Patch4: autofs-5.0.1-check-mtab-updated.patch
Patch5: autofs-5.0.1-file-map-allow-white-space-only-line.patch
Patch6: autofs-5.0.1-network_match-fix.patch
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: autoconf, hesiod-devel, openldap-devel, bison, flex, libxml2-devel, cyrus-sasl-devel, openssl-devel
Conflicts: kernel < 2.6.17
@ -61,6 +62,7 @@ echo %{version}-%{release} > .version
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%build
#CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=/usr --libdir=%{_libdir}
@ -113,6 +115,9 @@ fi
%{_libdir}/autofs/
%changelog
* Thu Mar 8 2007 Ian Kent <ikent@redhat.com> - 5.0.1-4
- fixed numeric export match (bz 231188).
* Thu Mar 1 2007 Ian Kent <ikent@redhat.com> - 5.0.1-3
- change file map lexer to allow white-space only blank lines (bz 229434).