A small memory footprint AMQP implimentation
Dependents: iothub_client_sample_amqp remote_monitoring simplesample_amqp
Diff: header_detect_io.c
- Revision:
- 38:7631b92cc772
- Parent:
- 30:0407b2db334c
- Child:
- 43:4c1e4e94cdd3
diff -r c923ba7f6cf9 -r 7631b92cc772 header_detect_io.c --- a/header_detect_io.c Fri Dec 15 14:09:42 2017 -0800 +++ b/header_detect_io.c Tue Jan 30 08:21:55 2018 -0800 @@ -132,6 +132,14 @@ } } +// This callback usage needs to be either verified and commented or integrated into +// the state machine. +static void unchecked_on_send_complete(void* context, IO_SEND_RESULT send_result) +{ + (void)context; + (void)send_result; +} + static void on_underlying_io_bytes_received(void* context, const unsigned char* buffer, size_t size) { if (context == NULL) @@ -317,7 +325,7 @@ { /* all header matches failed, we can't proceed, send back to the peer the first header we know of, */ /* then close as per spec. We do not care if we fail sending */ - if (xio_send(header_detect_io_instance->underlying_io, header_detect_io_instance->header_detect_entries[0].header_bytes, header_detect_io_instance->header_detect_entries[0].header_size, NULL, NULL) != 0) + if (xio_send(header_detect_io_instance->underlying_io, header_detect_io_instance->header_detect_entries[0].header_bytes, header_detect_io_instance->header_detect_entries[0].header_size, unchecked_on_send_complete, NULL) != 0) { LogError("Failed sending header"); }