summaryrefslogtreecommitdiffstats
path: root/sysdep
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>2000-06-17 01:12:47 +0200
committerMartin Mares <mj@ucw.cz>2000-06-17 01:12:47 +0200
commit4daf03e5138dea8e5c409ab20a07f35667caa89e (patch)
tree1edcb327630e449cf1542ff1089aa1c74a7b6c66 /sysdep
parent365211d5886ec59a543e9fbc2151d6218561c18c (diff)
downloadbird-4daf03e5138dea8e5c409ab20a07f35667caa89e.tar
bird-4daf03e5138dea8e5c409ab20a07f35667caa89e.zip
Use our own SUN_LEN if libc doesn't provide it.
Diffstat (limited to 'sysdep')
-rw-r--r--sysdep/unix/unix.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/sysdep/unix/unix.h b/sysdep/unix/unix.h
index 5da925c..bb4d063 100644
--- a/sysdep/unix/unix.h
+++ b/sysdep/unix/unix.h
@@ -34,6 +34,10 @@ typedef struct sockaddr_in6 sockaddr;
typedef struct sockaddr_in sockaddr;
#endif
+#ifndef SUN_LEN
+#define SUN_LEN(ptr) ((size_t) (((struct sockaddr_un *) 0)->sun_path) + strlen ((ptr)->sun_path))
+#endif
+
struct birdsock;
void io_init(void);