← cproj

add string struct

ca8804736e989bd6155c6c2b270553216db466d2 · ovidiucs · Oct 13, 2019 22:22

+7 · 1 file changed

  • graph/sockets/http_server.c +7 −0
diff --git a/graph/sockets/http_server.c b/graph/sockets/http_server.c
index a4eccb0..18c0312 100644
--- a/graph/sockets/http_server.c
+++ b/graph/sockets/http_server.c
@@ -8,6 +8,13 @@
 #include <setjmp.h> // for jump 
 #include <sys/types.h>
 #include <sys/socket.h>
+
+// ----------------------------------------------------------------
+
+typedef struct __attribute__((packed)){
+    uint64_t len;
+    char *data;
+} String;
 // ----------------------------------------------------------------
 
 //#define PORT 6969