diff options
author | root <root@rshg054.dnsready.net> | 2012-07-30 00:02:11 +0000 |
---|---|---|
committer | root <root@rshg054.dnsready.net> | 2012-07-30 00:02:11 +0000 |
commit | 4982c269b318734d01ad30c6592fbb73565ceb12 (patch) | |
tree | f8696db6a843a65a264dbfed979f087b1d62c011 /testing/dhcp/dhcp-4.1.1-missing-ipv6-not-fatal.patch | |
parent | ddab05fd84b7fa1d67fcd18b532f0427189d8df1 (diff) |
Mon Jul 30 00:02:11 UTC 2012
Diffstat (limited to 'testing/dhcp/dhcp-4.1.1-missing-ipv6-not-fatal.patch')
-rw-r--r-- | testing/dhcp/dhcp-4.1.1-missing-ipv6-not-fatal.patch | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/testing/dhcp/dhcp-4.1.1-missing-ipv6-not-fatal.patch b/testing/dhcp/dhcp-4.1.1-missing-ipv6-not-fatal.patch new file mode 100644 index 000000000..cc5ddb843 --- /dev/null +++ b/testing/dhcp/dhcp-4.1.1-missing-ipv6-not-fatal.patch @@ -0,0 +1,39 @@ +--- common/discover.c 2009-09-29 21:44:49.000000000 +0200 ++++ common/discover.c_new 2010-06-30 19:40:02.000000000 +0200 +@@ -443,7 +443,7 @@ + } + + #ifdef DHCPv6 +- if (local_family == AF_INET6) { ++ if ((local_family == AF_INET6) && !access("/proc/net/if_inet6", R_OK)) { + ifaces->fp6 = fopen("/proc/net/if_inet6", "r"); + if (ifaces->fp6 == NULL) { + log_error("Error opening '/proc/net/if_inet6' to " +@@ -454,6 +454,8 @@ + ifaces->fp = NULL; + return 0; + } ++ } else { ++ ifaces->fp6 = NULL; + } + #endif + +@@ -721,7 +723,7 @@ + return 1; + } + #ifdef DHCPv6 +- if (!(*err)) { ++ if (!(*err) && ifaces->fp6) { + if (local_family == AF_INET6) + return next_iface6(info, err, ifaces); + } +@@ -740,7 +742,8 @@ + ifaces->sock = -1; + #ifdef DHCPv6 + if (local_family == AF_INET6) { +- fclose(ifaces->fp6); ++ if(ifaces->fp6) ++ fclose(ifaces->fp6); + ifaces->fp6 = NULL; + } + #endif |