summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/socket/raddrinfo.c4
-rw-r--r--ext/socket/rubysocket.h2
-rw-r--r--ext/socket/unixsocket.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/ext/socket/raddrinfo.c b/ext/socket/raddrinfo.c
index fdc3d4e61cf..79943c79e23 100644
--- a/ext/socket/raddrinfo.c
+++ b/ext/socket/raddrinfo.c
@@ -443,7 +443,7 @@ rsock_unixaddr(struct sockaddr_un *sockaddr, socklen_t len)
}
socklen_t
-rsock_unixpath_len(VALUE path)
+rsock_unix_sockaddr_len(VALUE path)
{
#ifdef __linux__
if (RSTRING_PTR(path)[0] == '\0') {
@@ -800,7 +800,7 @@ init_unix_addrinfo(rb_addrinfo_t *rai, VALUE path, int socktype)
un.sun_family = AF_UNIX;
memcpy((void*)&un.sun_path, RSTRING_PTR(path), RSTRING_LEN(path));
- len = rsock_unixpath_len(path);
+ len = rsock_unix_sockaddr_len(path);
init_addrinfo(rai, (struct sockaddr *)&un, len,
PF_UNIX, socktype, 0, Qnil, Qnil);
}
diff --git a/ext/socket/rubysocket.h b/ext/socket/rubysocket.h
index c27b164188f..ff91f51bb7e 100644
--- a/ext/socket/rubysocket.h
+++ b/ext/socket/rubysocket.h
@@ -240,7 +240,7 @@ int rsock_revlookup_flag(VALUE revlookup, int *norevlookup);
#ifdef HAVE_SYS_UN_H
VALUE rsock_unixpath_str(struct sockaddr_un *sockaddr, socklen_t len);
VALUE rsock_unixaddr(struct sockaddr_un *sockaddr, socklen_t len);
-socklen_t rsock_unixpath_len(VALUE path);
+socklen_t rsock_unix_sockaddr_len(VALUE path);
#endif
int rsock_socket(int domain, int type, int proto);
diff --git a/ext/socket/unixsocket.c b/ext/socket/unixsocket.c
index e7693356b52..7bc523b1457 100644
--- a/ext/socket/unixsocket.c
+++ b/ext/socket/unixsocket.c
@@ -46,7 +46,7 @@ rsock_init_unixsock(VALUE sock, VALUE path, int server)
RSTRING_LEN(path), (int)sizeof(sockaddr.sun_path));
}
memcpy(sockaddr.sun_path, RSTRING_PTR(path), RSTRING_LEN(path));
- sockaddrlen = rsock_unixpath_len(path);
+ sockaddrlen = rsock_unix_sockaddr_len(path);
if (server) {
status = bind(fd, (struct sockaddr*)&sockaddr, sockaddrlen);