summaryrefslogtreecommitdiff
path: root/netio.h
diff options
context:
space:
mode:
authorLuke T. Shumaker <lukeshu@lukeshu.com>2024-09-26 19:36:54 -0600
committerLuke T. Shumaker <lukeshu@lukeshu.com>2024-09-26 19:36:54 -0600
commit71e1a86a033c380f85dd300d788af63bfef25bab (patch)
tree07aa53d5a933ba51535a78972edbfe0cd95a31c5 /netio.h
parentf5da707e77ee954b12f3c961012e4f40fa4e1bd3 (diff)
wip reorg
Diffstat (limited to 'netio.h')
-rw-r--r--netio.h18
1 files changed, 0 insertions, 18 deletions
diff --git a/netio.h b/netio.h
deleted file mode 100644
index 8497330..0000000
--- a/netio.h
+++ /dev/null
@@ -1,18 +0,0 @@
-#ifndef _NETIO_H_
-#define _NETIO_H_
-
-#include <stdbool.h> /* for bool */
-#include <stdint.h> /* for size_t, ssize_t, uint16_t */
-
-/** Return socket-fd on success, -errno on error. */
-int netio_listen(uint16_t port);
-/** Return connection-fd on success, -errno on error. */
-int netio_accept(int sock);
-/** Return bytes-read on success, 0 on EOF, -errno on error; a short read is *not* an error. */
-ssize_t netio_read(int conn, void *buf, size_t count);
-/** Return `count` on success, -errno on error; a short write *is* an error. */
-ssize_t netio_write(int conn, void *buf, size_t count);
-/** Return 0 on success, -errno on error. */
-int netio_close(int conn, bool rd, bool wr);
-
-#endif /* _NETIO_H_ */