]> git.meshlink.io Git - meshlink/blobdiff - src/sptps.h
Add support for sendmmsg().
[meshlink] / src / sptps.h
index c91d3882b428d09ea5c4d4f9154941a83a0727ed..5d567116a87e14a6a37cea2011b5c9c9127f5851 100644 (file)
@@ -53,7 +53,7 @@ typedef struct sptps {
 
        // Main member variables
        char *inbuf;
-       size_t buflen;
+       size_t inbuflen;
 
        chacha_poly1305_ctx_t *incipher;
        uint32_t replaywin;
@@ -61,6 +61,9 @@ typedef struct sptps {
        uint32_t received;
        uint16_t reclen;
 
+       char *outbuf;
+       size_t outbuflen;
+
        chacha_poly1305_ctx_t *outcipher;
        uint32_t outseqno;
 
@@ -96,5 +99,6 @@ extern bool sptps_send_record(sptps_t *s, uint8_t type, const void *data, uint16
 extern bool sptps_receive_data(sptps_t *s, const void *data, size_t len) __attribute__((__warn_unused_result__));
 extern bool sptps_force_kex(sptps_t *s) __attribute__((__warn_unused_result__));
 extern bool sptps_verify_datagram(sptps_t *s, const void *data, size_t len) __attribute__((__warn_unused_result__));
+extern void sptps_set_send_buffer(sptps_t *s, void *data, size_t len);
 
 #endif