A small memory footprint AMQP implimentation

Dependents:   iothub_client_sample_amqp remote_monitoring simplesample_amqp

Revision:
20:206846c14c80
Parent:
19:000ab4e6a2c1
Child:
21:f9c433d8e6ca
diff -r 000ab4e6a2c1 -r 206846c14c80 message_sender.c
--- a/message_sender.c	Fri Feb 24 14:00:58 2017 -0800
+++ b/message_sender.c	Fri Mar 10 11:47:49 2017 -0800
@@ -425,12 +425,12 @@
             {
                 amqpvalue_destroy(body_amqp_value);
             }
+        }
 
-            amqpvalue_destroy(application_properties);
-            amqpvalue_destroy(application_properties_value);
-            amqpvalue_destroy(properties_amqp_value);
-            properties_destroy(properties);
-        }
+        amqpvalue_destroy(application_properties);
+        amqpvalue_destroy(application_properties_value);
+        amqpvalue_destroy(properties_amqp_value);
+        properties_destroy(properties);
     }
 
     return result;
@@ -723,11 +723,6 @@
                             default:
                             case SEND_ONE_MESSAGE_ERROR:
 							
-								if (message_with_callback->on_message_send_complete != NULL)
-								{
-									message_with_callback->on_message_send_complete(message_with_callback->context, MESSAGE_SEND_ERROR);
-								}
-
                                 remove_pending_message_by_index(message_sender_instance, message_sender_instance->message_count - 1);
                                 result = __FAILURE__;
                                 break;