pimd: use socklen_t consistently
diff --git a/pimd/pim_cmd.c b/pimd/pim_cmd.c
index c37e961..dd06b07 100644
--- a/pimd/pim_cmd.c
+++ b/pimd/pim_cmd.c
@@ -2222,7 +2222,7 @@
char source_str[100];
char ss_uptime[10];
struct sockaddr_in bind_addr;
- int len = sizeof(bind_addr);
+ socklen_t len = sizeof(bind_addr);
char bind_addr_str[100];
pim_inet4_dump("<src?>", ss->source_addr, source_str, sizeof(source_str));
diff --git a/pimd/pim_sock.c b/pimd/pim_sock.c
index 2e78605..b80c0a2 100644
--- a/pimd/pim_sock.c
+++ b/pimd/pim_sock.c
@@ -375,7 +375,7 @@
return loop;
}
-int pim_socket_getsockname(int fd, struct sockaddr *name, int *namelen)
+int pim_socket_getsockname(int fd, struct sockaddr *name, socklen_t *namelen)
{
if (getsockname(fd, name, namelen)) {
int e = errno;
diff --git a/pimd/pim_sock.h b/pimd/pim_sock.h
index 3f026dc..29b5aee 100644
--- a/pimd/pim_sock.h
+++ b/pimd/pim_sock.h
@@ -52,6 +52,6 @@
int pim_socket_mcastloop_get(int fd);
-int pim_socket_getsockname(int fd, struct sockaddr *name, int *namelen);
+int pim_socket_getsockname(int fd, struct sockaddr *name, socklen_t *namelen);
#endif /* PIM_SOCK_H */