diff options
| author | 2017-12-30 03:29:35 +0100 | |
|---|---|---|
| committer | 2017-12-30 03:29:35 +0100 | |
| commit | ccb5ff9bb3a75d6ceac19e193eac447f7e84de79 (patch) | |
| tree | 6ca666ad8a1916dfcf0a016ec06ff43fb3f5c42a /src/safe_rw.h | |
| parent | f1e3970b52886c2e784d9d6a247788924eec6941 (diff) | |
| download | tweetpipe-ccb5ff9bb3a75d6ceac19e193eac447f7e84de79.tar.gz | |
Move things to src/
Diffstat (limited to 'src/safe_rw.h')
| -rw-r--r-- | src/safe_rw.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/safe_rw.h b/src/safe_rw.h new file mode 100644 index 0000000..31f4aa6 --- /dev/null +++ b/src/safe_rw.h @@ -0,0 +1,15 @@ +#ifndef safe_rw_H +#define safe_rw_H + +#include <stdlib.h> +#include <sys/types.h> + +ssize_t safe_write(const int fd, const void* const buf_, size_t count, + const int timeout); + +ssize_t safe_read(const int fd, void* const buf_, size_t count); + +ssize_t safe_read_partial(const int fd, void* const buf_, + const size_t max_count); + +#endif |