We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 8803b75 + ce25da1 commit 9cd8883Copy full SHA for 9cd8883
src/websocket.c
@@ -25,6 +25,10 @@
25
#endif
26
27
28
+#ifndef htons
29
+#include <arpa/inet.h>
30
+#endif
31
+
32
typedef int8_t ws_state;
33
#define STATE_ERROR 1
34
#define STATE_READ_HTTP_REQUEST 2
@@ -322,9 +326,7 @@ ws_status ws_send_frame(ws_t self,
322
326
memcpy(out_tail, &sz64, payload_n);
323
327
}
324
328
325
- int i;
- for (i = 0; i < payload_n; i++)
- *out_tail++;
329
+ out_tail += payload_n;
330
331
332
if (is_masking) {
0 commit comments