Azure IoT common library
Dependents: STM32F746_iothub_client_sample_mqtt f767zi_mqtt iothub_client_sample_amqp iothub_client_sample_http ... more
Diff: map.c
- Revision:
- 21:b92006c5b9ff
- Parent:
- 19:2e0811512ceb
- Child:
- 27:8656a313842b
diff -r 95abdea56064 -r b92006c5b9ff map.c --- a/map.c Fri Feb 10 17:01:36 2017 -0800 +++ b/map.c Fri Feb 24 14:01:41 2017 -0800 @@ -4,6 +4,7 @@ #include <stdlib.h> #include "azure_c_shared_utility/gballoc.h" #include "azure_c_shared_utility/map.h" +#include "azure_c_shared_utility/optimize_size.h" #include "azure_c_shared_utility/xlogging.h" #include "azure_c_shared_utility/strings.h" @@ -164,7 +165,7 @@ if (newKeys == NULL) { LogError("realloc error"); - result = __LINE__; + result = __FAILURE__; } else { @@ -192,7 +193,7 @@ handleData->keys = undoneKeys; } } - result = __LINE__; + result = __FAILURE__; } else { @@ -295,7 +296,7 @@ int result; if (Map_IncreaseStorageKeysValues(handleData) != 0) /*this increases handleData->count*/ { - result = __LINE__; + result = __FAILURE__; } else { @@ -303,7 +304,7 @@ { Map_DecreaseStorageKeysValues(handleData); LogError("unable to mallocAndStrcpy_s"); - result = __LINE__; + result = __FAILURE__; } else { @@ -312,7 +313,7 @@ free(handleData->keys[handleData->count - 1]); Map_DecreaseStorageKeysValues(handleData); LogError("unable to mallocAndStrcpy_s"); - result = __LINE__; + result = __FAILURE__; } else {