diff options
author | Marcel Raad <raad@teamviewer.com> | 2017-06-20 22:33:56 +0200 |
---|---|---|
committer | Marcel Raad <raad@teamviewer.com> | 2017-06-20 22:33:56 +0200 |
commit | 651e04c4c88ae6969be416e4a7a1ffe61d7a67e9 (patch) | |
tree | e72fecf5b37edfbbe1d7d933e526faec995e14cc /lib/if2ip.c | |
parent | 0feb762fc076d46d386793a0f7280373d706bbf1 (diff) | |
download | curl-651e04c4c88ae6969be416e4a7a1ffe61d7a67e9.tar.gz |
if2ip: fix compiler warning in ISO C90 mode
remote_scope_id is only used when both HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID
and ENABLE_IPV6 are defined instead of only one of them.
Diffstat (limited to 'lib/if2ip.c')
-rw-r--r-- | lib/if2ip.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/if2ip.c b/lib/if2ip.c index 4de81be60..3e74cc687 100644 --- a/lib/if2ip.c +++ b/lib/if2ip.c @@ -121,11 +121,11 @@ if2ip_result_t Curl_if2ip(int af, unsigned int remote_scope, #ifndef ENABLE_IPV6 (void) remote_scope; - -#ifndef HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID - (void) remote_scope_id; #endif +#if !defined(HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID) || \ + !defined(ENABLE_IPV6) + (void) remote_scope_id; #endif if(getifaddrs(&head) >= 0) { |