summaryrefslogtreecommitdiff
path: root/src/headers
diff options
context:
space:
mode:
Diffstat (limited to 'src/headers')
-rw-r--r--src/headers/bits-header4
-rw-r--r--src/headers/ip46-footer2
-rw-r--r--src/headers/ip46-header11
-rw-r--r--src/headers/ip46-with6
-rw-r--r--src/headers/ip46-without2
-rw-r--r--src/headers/types-header1
6 files changed, 14 insertions, 12 deletions
diff --git a/src/headers/bits-header b/src/headers/bits-header
index e96eecc..96c422a 100644
--- a/src/headers/bits-header
+++ b/src/headers/bits-header
@@ -1,7 +1,7 @@
/* ISC license. */
-#ifndef UINT@BITS@_H
-#define UINT@BITS@_H
+#ifndef SKALIBS_UINT@BITS@_H
+#define SKALIBS_UINT@BITS@_H
#include <stddef.h>
#include <stdint.h>
diff --git a/src/headers/ip46-footer b/src/headers/ip46-footer
index 4be22b5..a1062bf 100644
--- a/src/headers/ip46-footer
+++ b/src/headers/ip46-footer
@@ -4,7 +4,7 @@
#define socket_recvnb46_g(fd, buf, len, i, port, deadline) socket_recvnb46(fd, buf, len, i, port, (deadline), &STAMP)
#define socket_sendnb46_g(fd, buf, len, i, port, deadline) socket_sendnb46(fd, buf, len, i, port, (deadline), &STAMP)
-extern int socket_deadlineconnstamp46 (int, ip46_t const *, uint16_t, tain_t const *, tain_t *) ;
+extern int socket_deadlineconnstamp46 (int, ip46 const *, uint16_t, tain const *, tain *) ;
#define socket_deadlineconnstamp46_g(fd, ip, port, deadline) socket_deadlineconnstamp46(fd, ip, port, (deadline), &STAMP)
#endif
diff --git a/src/headers/ip46-header b/src/headers/ip46-header
index 3f872be..82c5e81 100644
--- a/src/headers/ip46-header
+++ b/src/headers/ip46-header
@@ -1,11 +1,12 @@
/* ISC license. */
-#ifndef IP46_H
-#define IP46_H
+#ifndef SKALIBS_IP46_H
+#define SKALIBS_IP46_H
#include <string.h>
#include <stdint.h>
#include <errno.h>
+
#include <skalibs/fmtscan.h>
#include <skalibs/socket.h>
@@ -15,7 +16,7 @@
#define IP4_LOCAL "\177\0\0\1"
#define IP6_LOCAL "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\1"
-typedef struct ip46full_s ip46full_t, *ip46full_t_ref ;
+typedef struct ip46full_s ip46full, *ip46full_ref ;
struct ip46full_s
{
@@ -26,8 +27,8 @@ struct ip46full_s
#define ip46full_is6(i) ((i)->is6)
#define ip46full_fmt(s, i) ((i)->is6 ? ip6_fmt(s, (i)->ip) : ip4_fmt(s, (i)->ip))
-extern size_t ip46full_scan (char const *, ip46full_t *) ;
-extern size_t ip46full_scanlist (ip46full_t *, size_t, char const *, size_t *) ;
+extern size_t ip46full_scan (char const *, ip46full *) ;
+extern size_t ip46full_scanlist (ip46full *, size_t, char const *, size_t *) ;
#define ip46full_from_ip4(i, ip4) (memcpy((i)->ip, ip4, 4), memset((i)->ip + 4, 0, 12), (i)->is6 = 0)
#define ip46full_from_ip6(i, ip6) (memcpy((i)->ip, ip6, 16), (i)->is6 = 1)
diff --git a/src/headers/ip46-with b/src/headers/ip46-with
index 9570ffa..14ac5bd 100644
--- a/src/headers/ip46-with
+++ b/src/headers/ip46-with
@@ -1,4 +1,4 @@
-typedef ip46full_t ip46_t, *ip46_t_ref ;
+typedef ip46full ip46, *ip46_ref ;
#define IP46_ZERO IP46FULL_ZERO
#define SKALIBS_IPV6_ENABLED
@@ -17,8 +17,8 @@ typedef ip46full_t ip46_t, *ip46_t_ref ;
#define socket_udp46(h) ((h) ? socket_udp6() : socket_udp4())
#define socket_recv46(fd, s, len, i, port) ((i)->is6 ? socket_recv6(fd, s, len, (i)->ip, port) : socket_recv4(fd, s, len, (i)->ip, port))
#define socket_send46(fd, s, len, i, port) ((i)->is6 ? socket_send6(fd, s, len, (i)->ip, port) : socket_send4(fd, s, len, (i)->ip, port))
-extern int socket_local46 (int, ip46_t *, uint16_t *) ;
-extern int socket_remote46 (int, ip46_t *, uint16_t *) ;
+extern int socket_local46 (int, ip46 *, uint16_t *) ;
+extern int socket_remote46 (int, ip46 *, uint16_t *) ;
#define socket_recvnb46(fd, buf, len, i, port, deadline, stamp) ((i)->is6 ? socket_recvnb6(fd, buf, len, (i)->ip, port, deadline, stamp) : socket_recvnb4(fd, buf, len, (i)->ip, port, deadline, stamp))
#define socket_sendnb46(fd, buf, len, i, port, deadline, stamp) ((i)->is6 ? socket_sendnb6(fd, buf, len, (i)->ip, port, deadline, stamp) : socket_sendnb4(fd, buf, len, (i)->ip, port, deadline, stamp))
diff --git a/src/headers/ip46-without b/src/headers/ip46-without
index c06106b..43d3038 100644
--- a/src/headers/ip46-without
+++ b/src/headers/ip46-without
@@ -1,4 +1,4 @@
-typedef struct ip46_s ip46_t, *ip46_t_ref ;
+typedef struct ip46_s ip46, *ip46_ref ;
struct ip46_s
{
char ip[4] ;
diff --git a/src/headers/types-header b/src/headers/types-header
index 015bb08..c3b3e76 100644
--- a/src/headers/types-header
+++ b/src/headers/types-header
@@ -5,6 +5,7 @@
#include <sys/types.h>
#include <stdint.h>
+
#include <skalibs/uint16.h>
#include <skalibs/uint32.h>
#include <skalibs/uint64.h>