From 7ac927bd59e8bf015000d24e44b990cef04e06de Mon Sep 17 00:00:00 2001 From: gaurav-aws Date: Tue, 23 Jul 2019 04:49:24 +0000 Subject: [PATCH] Remove IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ) from MQTT code The cut down version of the task pool has only one task pool, namely, system task pool. All the task pool API functions accept NULL as a valid parameter for IotTaskPool_t and use the system task pool when NULL is passed for the system task pool. IOT_SYSTEM_TASKPOOL is defined to NULL to use system task pool and therefore the above assert is no longer valid. git-svn-id: https://svn.code.sf.net/p/freertos/code/trunk@2698 1d2547de-c912-0410-9cb9-b8ca96c0e9e2 --- .../c_sdk/standard/mqtt/src/iot_mqtt_operation.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/FreeRTOS-Plus/Source/FreeRTOS-IoT-Libraries/c_sdk/standard/mqtt/src/iot_mqtt_operation.c b/FreeRTOS-Plus/Source/FreeRTOS-IoT-Libraries/c_sdk/standard/mqtt/src/iot_mqtt_operation.c index 7923d62b3..bfe08d7b2 100644 --- a/FreeRTOS-Plus/Source/FreeRTOS-IoT-Libraries/c_sdk/standard/mqtt/src/iot_mqtt_operation.c +++ b/FreeRTOS-Plus/Source/FreeRTOS-IoT-Libraries/c_sdk/standard/mqtt/src/iot_mqtt_operation.c @@ -656,7 +656,7 @@ void _IotMqtt_ProcessKeepAlive( IotTaskPool_t pTaskPool, _mqttConnection_t * pMqttConnection = ( _mqttConnection_t * ) pContext; /* Check parameters. */ - IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); + /* IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); */ IotMqtt_Assert( pKeepAliveJob == pMqttConnection->keepAliveJob ); /* Check that keep-alive interval is valid. The MQTT spec states its maximum @@ -786,7 +786,7 @@ void _IotMqtt_ProcessIncomingPublish( IotTaskPool_t pTaskPool, * are disabled. */ ( void ) pTaskPool; ( void ) pPublishJob; - IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); + /* IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); */ IotMqtt_Assert( pOperation->incomingPublish == true ); IotMqtt_Assert( pPublishJob == pOperation->job ); @@ -839,7 +839,7 @@ void _IotMqtt_ProcessSend( IotTaskPool_t pTaskPool, * are disabled. */ ( void ) pTaskPool; ( void ) pSendJob; - IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); + /* IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); */ IotMqtt_Assert( pSendJob == pOperation->job ); /* The given operation must have an allocated packet and be waiting for a status. */ @@ -1020,7 +1020,7 @@ void _IotMqtt_ProcessCompletedOperation( IotTaskPool_t pTaskPool, * are disabled. */ ( void ) pTaskPool; ( void ) pOperationJob; - IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); + /* IotMqtt_Assert( pTaskPool == IOT_SYSTEM_TASKPOOL ); */ IotMqtt_Assert( pOperationJob == pOperation->job ); /* The operation's callback function and status must be set. */ -- 2.39.2