diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2012-03-14 17:16:28 +0100 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2012-03-14 17:16:28 +0100 |
commit | d9ed50094da3890b10872a4955dceb2817931f1f (patch) | |
tree | 15f83f511489e46bbb1df5ff2443a784b0a43815 /src/method_null.c | |
parent | 4cdee0ee4745a5bb44b9f2c95812cb4f1aea0a31 (diff) | |
download | fastd-d9ed50094da3890b10872a4955dceb2817931f1f.tar fastd-d9ed50094da3890b10872a4955dceb2817931f1f.zip |
Require libuecc; rename cfxp to ecfxp; add some basic infrastructure for crypto implementation
Diffstat (limited to 'src/method_null.c')
-rw-r--r-- | src/method_null.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/method_null.c b/src/method_null.c index e8d8f58..f5a0d74 100644 --- a/src/method_null.c +++ b/src/method_null.c @@ -81,11 +81,15 @@ static char* method_peer_str(const fastd_context *ctx, const fastd_peer *peer) { } static void method_init(fastd_context *ctx, fastd_peer *peer) { + pr_info(ctx, "Connection with %P established.", peer); + fastd_task_put_send(ctx, peer, fastd_buffer_alloc(0, 0, 0)); } static void method_handle_recv(fastd_context *ctx, fastd_peer *peer, fastd_buffer buffer) { if (!fastd_peer_is_established(peer)) { + pr_info(ctx, "Connection with %P established.", peer); + fastd_peer_set_established(ctx, peer); } @@ -114,6 +118,9 @@ static void method_send(fastd_context *ctx, fastd_peer *peer, fastd_buffer buffe fastd_task_put_send(ctx, peer, buffer); } +static void method_free_peer_private(fastd_context *ctx, fastd_peer *peer) { +} + const fastd_method fastd_method_null = { .name = "null", @@ -127,4 +134,6 @@ const fastd_method fastd_method_null = { .init = method_init, .handle_recv = method_handle_recv, .send = method_send, + + .free_peer_private = method_free_peer_private, }; |