From 810de0a90148d5dc7fe5919949220a00d14f6447 Mon Sep 17 00:00:00 2001 From: Ren Kararou Date: Mon, 30 Dec 2024 15:30:46 -0600 Subject: fix silly errors in last commit; start impl of handlers --- inc/handlers.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 inc/handlers.h (limited to 'inc') diff --git a/inc/handlers.h b/inc/handlers.h new file mode 100644 index 0000000..9f1988f --- /dev/null +++ b/inc/handlers.h @@ -0,0 +1,17 @@ +#ifndef NBD_NBTPD_HANDLERS_H +#define NBD_NBTPD_HANDLERS_H + +#include +#include "packet.h" + +typedef struct { + char path[768]; + char mode[32]; + struct sockaddr_in client; +} nbd_nbtpd_args; + +void read_req_resp(nbd_nbtpd_args args); +void write_req_resp(nbd_nbtpd_args args); +void nbd_nbtpd_resp_error(nbd_nbtpd_args args); + +#endif -- cgit 1.4.1-2-gfad0