blob: 8ee5c5447f0d7b573d566487f8da06e5752c4dd5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
/* ISC license. */
#include <sys/types.h>
#include <errno.h>
#include <skalibs/buffer.h>
int buffer_putallnoflush (buffer *b, char const *s, size_t len)
{
ssize_t r = buffer_putnoflush(b, s, len) ;
if (r < len)
{
buffer_unput(b, r) ;
return (errno = ENOBUFS, 0) ;
}
return 1 ;
}
|