parent
3e44d201b9
commit
5809fa5584
@ -1,6 +1,6 @@
|
|||||||
diff -up dhcp-4.2.3-P2/common/discover.c.getifaddrs dhcp-4.2.3-P2/common/discover.c
|
diff -up dhcp-4.2.3-P2/common/discover.c.getifaddrs dhcp-4.2.3-P2/common/discover.c
|
||||||
--- dhcp-4.2.3-P2/common/discover.c.getifaddrs 2012-03-21 16:28:08.537760099 +0100
|
--- dhcp-4.2.3-P2/common/discover.c.getifaddrs 2012-03-23 18:07:54.744082263 +0100
|
||||||
+++ dhcp-4.2.3-P2/common/discover.c 2012-03-21 16:29:58.134389955 +0100
|
+++ dhcp-4.2.3-P2/common/discover.c 2012-03-23 18:14:37.213050709 +0100
|
||||||
@@ -379,394 +379,13 @@ end_iface_scan(struct iface_conf_list *i
|
@@ -379,394 +379,13 @@ end_iface_scan(struct iface_conf_list *i
|
||||||
ifaces->sock = -1;
|
ifaces->sock = -1;
|
||||||
}
|
}
|
||||||
@ -397,16 +397,31 @@ diff -up dhcp-4.2.3-P2/common/discover.c.getifaddrs dhcp-4.2.3-P2/common/discove
|
|||||||
* function.
|
* function.
|
||||||
*
|
*
|
||||||
* The getifaddrs() man page describes the use.
|
* The getifaddrs() man page describes the use.
|
||||||
@@ -826,7 +445,12 @@ next_iface(struct iface_info *info, int
|
@@ -814,6 +433,8 @@ begin_iface_scan(struct iface_conf_list
|
||||||
|
*/
|
||||||
|
int
|
||||||
|
next_iface(struct iface_info *info, int *err, struct iface_conf_list *ifaces) {
|
||||||
|
+ size_t sa_len = 0;
|
||||||
|
+
|
||||||
|
if (ifaces->next == NULL) {
|
||||||
|
*err = 0;
|
||||||
|
return 0;
|
||||||
|
@@ -825,8 +446,16 @@ next_iface(struct iface_info *info, int
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
strcpy(info->name, ifaces->next->ifa_name);
|
strcpy(info->name, ifaces->next->ifa_name);
|
||||||
memcpy(&info->addr, ifaces->next->ifa_addr,
|
- memcpy(&info->addr, ifaces->next->ifa_addr,
|
||||||
|
- ifaces->next->ifa_addr->sa_len);
|
||||||
|
+
|
||||||
+#if __linux
|
+#if __linux
|
||||||
+ (ifaces->next->ifa_addr->sa_family== AF_INET) ?
|
+ if (ifaces->next->ifa_addr->sa_family == AF_INET)
|
||||||
+ sizeof(struct sockaddr_in) : sizeof(struct sockaddr_in6));
|
+ sa_len = sizeof(struct sockaddr_in);
|
||||||
|
+ else if (ifaces->next->ifa_addr->sa_family == AF_INET6)
|
||||||
|
+ sa_len = sizeof(struct sockaddr_in6);
|
||||||
+#else
|
+#else
|
||||||
ifaces->next->ifa_addr->sa_len);
|
+ sa_len = ifaces->next->ifa_addr->sa_len
|
||||||
+#endif
|
+#endif
|
||||||
|
+ memcpy(&info->addr, ifaces->next->ifa_addr, sa_len);
|
||||||
info->flags = ifaces->next->ifa_flags;
|
info->flags = ifaces->next->ifa_flags;
|
||||||
ifaces->next = ifaces->next->ifa_next;
|
ifaces->next = ifaces->next->ifa_next;
|
||||||
*err = 0;
|
*err = 0;
|
||||||
|
@ -22,7 +22,7 @@
|
|||||||
Summary: Dynamic host configuration protocol software
|
Summary: Dynamic host configuration protocol software
|
||||||
Name: dhcp
|
Name: dhcp
|
||||||
Version: 4.2.3
|
Version: 4.2.3
|
||||||
Release: 22.%{patchver}%{?dist}
|
Release: 23.%{patchver}%{?dist}
|
||||||
# NEVER CHANGE THE EPOCH on this package. The previous maintainer (prior to
|
# NEVER CHANGE THE EPOCH on this package. The previous maintainer (prior to
|
||||||
# dcantrell maintaining the package) made incorrect use of the epoch and
|
# dcantrell maintaining the package) made incorrect use of the epoch and
|
||||||
# that's why it is at 12 now. It should have never been used, but it was.
|
# that's why it is at 12 now. It should have never been used, but it was.
|
||||||
@ -624,6 +624,9 @@ fi
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Mar 23 2012 Jiri Popelka <jpopelka@redhat.com> - 12:4.2.3-23.P2
|
||||||
|
- improve #449946 fix (#806342)
|
||||||
|
|
||||||
* Wed Mar 21 2012 Jiri Popelka <jpopelka@redhat.com> - 12:4.2.3-22.P2
|
* Wed Mar 21 2012 Jiri Popelka <jpopelka@redhat.com> - 12:4.2.3-22.P2
|
||||||
- RFC5970 - DHCPv6 Options for Network Boot (#798735)
|
- RFC5970 - DHCPv6 Options for Network Boot (#798735)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user