OBS User unknown 2008-11-03 13:10:12 +00:00 committed by Git OBS Bridge
parent b4aedef7ed
commit 445084ed7b
3 changed files with 10 additions and 44 deletions

View File

@ -1,41 +0,0 @@
--- net-tools-1.60/ifconfig.c.orig 2008-10-22 19:27:21.000000000 +0530
+++ net-tools-1.60/ifconfig.c 2008-10-22 19:31:08.000000000 +0530
@@ -227,7 +227,7 @@ static int set_netmask(int skfd, struct
int main(int argc, char **argv)
{
- struct sockaddr sa;
+ struct sockaddr sa, sa_netmask;
struct sockaddr_in sin;
char host[128];
struct aftype *ap;
@@ -903,16 +903,13 @@ int main(int argc, char **argv)
/* FIXME: sa is too small for INET6 addresses, inet6 should use that too,
broadcast is unexpected */
if (ap->getmask) {
- switch (ap->getmask(host, &sa, NULL)) {
+ switch (ap->getmask(host, &sa_netmask, NULL)) {
case -1:
usage();
break;
case 1:
if (didnetmask)
usage();
-
- goterr = set_netmask(skfd, &ifr, &sa);
- didnetmask++;
break;
}
}
@@ -960,6 +957,11 @@ int main(int argc, char **argv)
}
}
+ if (!didnetmask) {
+ goterr = set_netmask(skfd, &ifr, &sa_netmask);
+ didnetmask++;
+ }
+
/*
* Don't do the set_flag() if the address is an alias with a - at the
* end, since it's deleted already! - Roman

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Fri Oct 31 16:20:54 CET 2008 - ms@suse.de
- reverted last patch from IBM because it breaks standard
ifconfig usage as shown in bug (bnc #440580)
-------------------------------------------------------------------
Mon Oct 27 15:33:44 CET 2008 - ms@suse.de

View File

@ -28,7 +28,7 @@ Provides: iputils:/usr/share/man/man8/traceroute6.1.gz
Obsoletes: traceroute net_tool
AutoReqProv: on
Version: 1.60
Release: 722
Release: 723
Summary: Important Programs for Networking
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Source: net-tools-%{version}.tar.bz2
@ -65,7 +65,6 @@ Patch28: traceroute-strip.diff
Patch30: net-tools-1.60-ifconfig.8.diff
Patch31: net-tools-1.60-tcp-recvq-listen.patch
Patch32: net-tools-1.60-netstat-ci.diff
Patch33: net-tools-1.60-ifconfig-SIOCSIFNETMASK.diff
%description
This package contains essential programs for network administration and
@ -116,7 +115,6 @@ cd ..
%patch30 -p1
%patch31 -p1
%patch32 -p1
%patch33 -p1
%build
make config
@ -170,6 +168,9 @@ rm -rf $RPM_BUILD_ROOT
%lang(pt_BR) %doc %_mandir/pt_BR/man*/*
%changelog
* Fri Oct 31 2008 ms@suse.de
- reverted last patch from IBM because it breaks standard
ifconfig usage as shown in bug (bnc #440580)
* Mon Oct 27 2008 ms@suse.de
- fixed ifconfig SIOCSIFNETMASK ioctl from being called earlier
to SIOCSIFADDR (bnc #438983)