summaryrefslogtreecommitdiff
path: root/src/libunixonacid/unixmessage_sender_timed_flush.c
blob: e144c82dc09966df3a9058b927537682623ef278 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* ISC license. */

#include <skalibs/functypes.h>
#include <skalibs/tai.h>
#include <skalibs/unix-timed.h>
#include <skalibs/unixmessage.h>

static int unixmessage_sender_isnonempty (unixmessage_sender_t *b)
{
  return !unixmessage_sender_isempty(b) ;
}

int unixmessage_sender_timed_flush (unixmessage_sender_t *b, tain_t const *deadline, tain_t *stamp)
{
  return timed_flush(b, (initfunc_t_ref)&unixmessage_sender_getfd, (initfunc_t_ref)&unixmessage_sender_isnonempty, (initfunc_t_ref)&unixmessage_sender_flush, deadline, stamp) ;
}