summaryrefslogtreecommitdiff
path: root/components/ip.c
diff options
context:
space:
mode:
authorAaron Marcher <me@drkhsh.at>2018-07-06 08:08:48 +0200
committerAaron Marcher <me@drkhsh.at>2018-07-06 08:08:48 +0200
commit51ff7ce2b99147a1a77ed243093865fc884e571a (patch)
tree5d5bb891f9143825b0f081cde6d2c27a9e49d80e /components/ip.c
parentefa26f4f3548bce8086abcd8de7ca135169e6f37 (diff)
Consistent paramter naming for components
Diffstat (limited to 'components/ip.c')
-rw-r--r--components/ip.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/components/ip.c b/components/ip.c
index f26e49a..a7b1bfd 100644
--- a/components/ip.c
+++ b/components/ip.c
@@ -11,7 +11,7 @@
#include "../util.h"
static const char *
-ip(const char *iface, unsigned short sa_family)
+ip(const char *interface, unsigned short sa_family)
{
struct ifaddrs *ifaddr, *ifa;
int s;
@@ -28,7 +28,7 @@ ip(const char *iface, unsigned short sa_family)
}
s = getnameinfo(ifa->ifa_addr, sizeof(struct sockaddr_in6),
host, NI_MAXHOST, NULL, 0, NI_NUMERICHOST);
- if (!strcmp(ifa->ifa_name, iface) &&
+ if (!strcmp(ifa->ifa_name, interface) &&
(ifa->ifa_addr->sa_family == sa_family)) {
freeifaddrs(ifaddr);
if (s != 0) {
@@ -45,13 +45,13 @@ ip(const char *iface, unsigned short sa_family)
}
const char *
-ipv4(const char *iface)
+ipv4(const char *interface)
{
- return ip(iface, AF_INET);
+ return ip(interface, AF_INET);
}
const char *
-ipv6(const char *iface)
+ipv6(const char *interface)
{
- return ip(iface, AF_INET6);
+ return ip(interface, AF_INET6);
}