summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSusant Sahani <ssahani@users.noreply.github.com>2016-09-27 19:25:13 +0530
committerMartin Pitt <martin.pitt@ubuntu.com>2016-09-27 15:55:13 +0200
commit629abfc23f4e8d61ec0e952182e8200656b2bbe1 (patch)
treeb95fe811a6407a54ae51176c49c9ac0ab6b81ad2
parentb4c6f71b827d41a4af8007b735edf21ef7609f99 (diff)
basic: fix for IPv6 status (#4224)
Even if ``` cat /proc/sys/net/ipv6/conf/all/disable_ipv6 1 ``` is disabled cat /proc/net/sockstat6 ``` TCP6: inuse 2 UDP6: inuse 1 UDPLITE6: inuse 0 RAW6: inuse 0 FRAG6: inuse 0 memory 0 ``` Looking for /proc/net/if_inet6 is the right choice.
-rw-r--r--src/basic/socket-util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/basic/socket-util.c b/src/basic/socket-util.c
index 6093e47172..5c829e0e7e 100644
--- a/src/basic/socket-util.c
+++ b/src/basic/socket-util.c
@@ -441,7 +441,7 @@ const char* socket_address_get_path(const SocketAddress *a) {
}
bool socket_ipv6_is_supported(void) {
- if (access("/proc/net/sockstat6", F_OK) != 0)
+ if (access("/proc/net/if_inet6", F_OK) != 0)
return false;
return true;