diff options
author | Luke T. Shumaker <lukeshu@lukeshu.com> | 2024-10-27 23:22:01 -0600 |
---|---|---|
committer | Luke T. Shumaker <lukeshu@lukeshu.com> | 2024-10-27 23:49:37 -0600 |
commit | 88adb90f5e805bea27e619fd5209ef58dbff6fd1 (patch) | |
tree | c3e24877b40ce183f1d72f6e064b0478ecf92207 /cmd/srv9p/gnet.h | |
parent | 89761191a98f7dce4d1049b9a84c3d645378222a (diff) |
Factor out a libhw
Diffstat (limited to 'cmd/srv9p/gnet.h')
-rw-r--r-- | cmd/srv9p/gnet.h | 37 |
1 files changed, 0 insertions, 37 deletions
diff --git a/cmd/srv9p/gnet.h b/cmd/srv9p/gnet.h deleted file mode 100644 index 3e8a0f4..0000000 --- a/cmd/srv9p/gnet.h +++ /dev/null @@ -1,37 +0,0 @@ -/* srv9p/gnet.h - libmisc/net.h implementation for libcr + GNU libc - * - * Copyright (C) 2024 Luke T. Shumaker <lukeshu@lukeshu.com> - * SPDX-Licence-Identifier: AGPL-3.0-or-later - */ - -#ifndef _SRV9P_GNET_H_ -#define _SRV9P_GNET_H_ - -#include <stdint.h> /* for uint16_6 */ - -#include <libmisc/net.h> - -struct _gnet_tcp_conn { - implements_net_stream_conn; - - int fd; -}; - -struct gnet_tcp_listener { - implements_net_stream_listener; - - int fd; - struct _gnet_tcp_conn active_conn; -}; - -void gnet_tcp_listener_init(struct gnet_tcp_listener *self, uint16_t port); - -struct gnet_udp_conn { - implements_net_packet_conn; - - int fd; -}; - -void gnet_udp_conn_init(struct gnet_udp_conn *self, uint16_t port); - -#endif /* _SRV9P_GNET_H_ */ |