diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2021-07-28 23:45:20 +0000 |
---|---|---|
committer | Laurent Bercot <ska@appnovation.com> | 2021-07-28 23:45:20 +0000 |
commit | 9592bfd0dda7c575de07bce2c7a81b8432d845a4 (patch) | |
tree | 57c66c3e0dfeb63cfd3ebfef18e30a2145ae3f88 /src/libunixonacid/unixmessage_put.c | |
parent | c15bccec3fd551583ff838673ba284ee6c7e788a (diff) | |
download | skalibs-9592bfd0dda7c575de07bce2c7a81b8432d845a4.tar.xz |
Huge incompatible changes.
- Obsolete skalibs/environ.h and skalibs/getpeereid.h removed.
- rc4 and md5 removed.
- All *_t types renamed to avoid treading on POSIX namespace.
- subgetopt() renamed to lgetopt().
- signal functions reworked; skasigaction removed; sig_stack removed
- Various functions removed: skaoffsetof(), selfpipe_untrap()
- New posixplz function: munmap_void.
Signed-off-by: Laurent Bercot <ska@appnovation.com>
Diffstat (limited to 'src/libunixonacid/unixmessage_put.c')
-rw-r--r-- | src/libunixonacid/unixmessage_put.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libunixonacid/unixmessage_put.c b/src/libunixonacid/unixmessage_put.c index 9ce103d..a41c5c0 100644 --- a/src/libunixonacid/unixmessage_put.c +++ b/src/libunixonacid/unixmessage_put.c @@ -11,7 +11,7 @@ #include <skalibs/unixmessage.h> #include <skalibs/posixishard.h> -static inline int copyfds (char *s, int const *fds, unsigned int n, unsigned char const *bits, unixmessage_sender_closecb_func_t_ref closecb, void *closecbdata) +static inline int copyfds (char *s, int const *fds, unsigned int n, unsigned char const *bits, unixmessage_sender_closecb_func_ref closecb, void *closecbdata) { unsigned int i = 0 ; for (; i < n ; i++) @@ -25,7 +25,7 @@ static inline int copyfds (char *s, int const *fds, unsigned int n, unsigned cha return 1 ; } -static int reserve_and_copy (unixmessage_sender_t *b, size_t len, int const *fds, unsigned int nfds, unsigned char const *bits) +static int reserve_and_copy (unixmessage_sender *b, size_t len, int const *fds, unsigned int nfds, unsigned char const *bits) { disize cur = { .left = b->data.len, .right = genalloc_len(int, &b->fds) } ; if (len > UNIXMESSAGE_MAXSIZE || nfds > UNIXMESSAGE_MAXFDS) @@ -39,7 +39,7 @@ static int reserve_and_copy (unixmessage_sender_t *b, size_t len, int const *fds return genalloc_append(disize, &b->offsets, &cur) ; } -int unixmessage_put_and_close (unixmessage_sender_t *b, unixmessage_t const *m, unsigned char const *bits) +int unixmessage_put_and_close (unixmessage_sender *b, unixmessage const *m, unsigned char const *bits) { if (!reserve_and_copy(b, m->len, m->fds, m->nfds, bits)) return 0 ; memmove(b->data.s + b->data.len, m->s, m->len) ; @@ -47,7 +47,7 @@ int unixmessage_put_and_close (unixmessage_sender_t *b, unixmessage_t const *m, return 1 ; } -int unixmessage_putv_and_close (unixmessage_sender_t *b, unixmessage_v_t const *m, unsigned char const *bits) +int unixmessage_putv_and_close (unixmessage_sender *b, unixmessagev const *m, unsigned char const *bits) { size_t len = siovec_len(m->v, m->vlen) ; if (!reserve_and_copy(b, len, m->fds, m->nfds, bits)) return 0 ; |