1 #ifndef SAFE_RW_H
2 #define SAFE_RW_H
3 
4 #include <sys/types.h>
5 #include <assert.h>
6 #include <errno.h>
7 #include <poll.h>
8 #include <stdlib.h>
9 #include <unistd.h>
10 
11 ssize_t safe_write(const int fd, const void *const buf_, size_t count,
12                    const int timeout);
13 
14 ssize_t safe_read(const int fd, void *const buf_, size_t count);
15 
16 ssize_t safe_read_partial(const int fd, void *const buf_,
17                           const size_t max_count);
18 
19 #endif
20