Skip to content

Commit

Permalink
Fix the erroneous check (FreeRTOS#1210)
Browse files Browse the repository at this point in the history
This is to address this issue: FreeRTOS/FreeRTOS#1206
  • Loading branch information
xuelix authored Apr 17, 2024
1 parent 469b8ad commit 2023ac6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -801,7 +801,7 @@ BaseType_t xEstablishMqttSession( MQTTContext_t * pxMqttContext,
}
}

if( xReturnStatus == pdFAIL )
if( xReturnStatus != pdFAIL )
{
/* Keep a flag for indicating if MQTT session is established. This
* flag will mark that an MQTT DISCONNECT has to be sent at the end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -794,7 +794,7 @@ BaseType_t xEstablishMqttSession( MQTTContext_t * pxMqttContext,
}
}

if( xReturnStatus == pdFAIL )
if( xReturnStatus != pdFAIL )
{
/* Keep a flag for indicating if MQTT session is established. This
* flag will mark that an MQTT DISCONNECT has to be sent at the end
Expand Down

0 comments on commit 2023ac6

Please sign in to comment.