diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2014-05-25 04:59:35 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2014-05-25 04:59:35 +0200 |
commit | 5e72359e9a2f4008c408acbd3fe5d389e11a15b4 (patch) | |
tree | 5f1aede16a3b1e6985d4b7a309c6999416a638a3 /src/receive.c | |
parent | f34e51a1c3b98df2b7c8c7d7eb415a33f42f2d75 (diff) | |
download | fastd-5e72359e9a2f4008c408acbd3fe5d389e11a15b4.tar fastd-5e72359e9a2f4008c408acbd3fe5d389e11a15b4.zip |
Completely document fastd.h
Diffstat (limited to 'src/receive.c')
-rw-r--r-- | src/receive.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/receive.c b/src/receive.c index 9a528fe..e5c1aeb 100644 --- a/src/receive.c +++ b/src/receive.c @@ -179,6 +179,7 @@ static inline void handle_socket_receive(fastd_socket_t *sock, const fastd_peer_ } } +/** Reads a packet from a socket */ void fastd_receive(fastd_socket_t *sock) { size_t max_len = fastd_max_outer_packet(); fastd_buffer_t buffer = fastd_buffer_alloc(max_len, conf.min_decrypt_head_space, conf.min_decrypt_tail_space); @@ -241,6 +242,7 @@ static inline void handle_forward(fastd_peer_t *source_peer, fastd_buffer_t buff fastd_send_all(source_peer, buffer); } +/** Handles a received and decrypted payload packet */ void fastd_handle_receive(fastd_peer_t *peer, fastd_buffer_t buffer) { if (conf.mode == MODE_TAP) { if (buffer.len < ETH_HLEN) { |