A small memory footprint AMQP implimentation
Dependents: iothub_client_sample_amqp remote_monitoring simplesample_amqp
Diff: message_sender.c
- Revision:
- 16:22a72cf8e416
- Parent:
- 13:9abd748f4e78
- Child:
- 17:923575db8b2d
diff -r 5db103709f20 -r 22a72cf8e416 message_sender.c --- a/message_sender.c Sun Jan 08 11:12:13 2017 -0800 +++ b/message_sender.c Fri Jan 13 18:40:42 2017 -0800 @@ -102,7 +102,7 @@ if (message_with_callback->on_message_send_complete != NULL) { AMQP_VALUE descriptor = amqpvalue_get_inplace_descriptor(delivery_state); - if (descriptor == NULL) + if ((descriptor == NULL) && (delivery_state != NULL)) { LogError("Error getting descriptor for delivery state"); } @@ -145,8 +145,8 @@ if (xlogging_get_log_function() != NULL && message_sender_instance->is_trace_on == 1) { char* value_as_string = NULL; - LOG(LOG_TRACE, 0, "%s", name); - LOG(LOG_TRACE, 0, "%s", (value_as_string = amqpvalue_to_string(value))); + LOG(AZ_LOG_TRACE, 0, "%s", name); + LOG(AZ_LOG_TRACE, 0, "%s", (value_as_string = amqpvalue_to_string(value))); if (value_as_string != NULL) { amqpalloc_free(value_as_string);