summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sysdep/unix/io.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/sysdep/unix/io.c b/sysdep/unix/io.c
index 14bf99fe..5d269ec6 100644
--- a/sysdep/unix/io.c
+++ b/sysdep/unix/io.c
@@ -1512,6 +1512,17 @@ sk_open_unix(sock *s, char *name)
return 0;
}
+static void hexdump(const char *data, socklen_t size)
+{
+ char buf[1024];
+
+ for (int i = 0; i < size; i++)
+ {
+ sprintf(buf + i*3, "%02x ", data[i]);
+ }
+ log(L_DEBUG, "sk_connect_unix: %s", buf);
+}
+
int
sk_connect_unix(sock *s, char *name, socklen_t namelen)
{
@@ -1535,6 +1546,7 @@ sk_connect_unix(sock *s, char *name, socklen_t namelen)
sa.sun_family = AF_UNIX;
memcpy(sa.sun_path, name, namelen);
+ hexdump((const char*)&sa, sizeof(sa.sun_family) + namelen);
if (connect(fd, (struct sockaddr *) &sa, sizeof(sa.sun_family) + namelen) < 0)
return -1;