Merge branch 'locez-bugfix-double-free-for-qos0' into develop

This commit is contained in:
Ian Craggs 2022-02-17 14:33:29 +00:00
commit c88c957e1a
1 changed files with 4 additions and 1 deletions

View File

@ -1441,7 +1441,10 @@ static int MQTTAsync_processCommand(void)
else
{
if (rc != SOCKET_ERROR)
command->command.details.pub.destinationName = NULL; /* this will be freed by the protocol code */
{
command->command.details.pub.payload = NULL; /* this will be freed by the protocol code */
command->command.details.pub.destinationName = NULL; /* this will be freed by the protocol code */
}
command->client->pending_write = &command->command;
}
}