mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
modbus: fix tcp slave destroy issues
Closes https://github.com/espressif/esp-idf/issues/8211
This commit is contained in:
parent
9338d1d121
commit
106fcdcc1c
@ -119,7 +119,7 @@ static esp_err_t mbc_tcp_slave_destroy(void)
|
||||
(void)vQueueDelete(mbs_opts->mbs_notification_queue_handle);
|
||||
(void)vEventGroupDelete(mbs_opts->mbs_event_group);
|
||||
(void)vMBTCPPortClose();
|
||||
|
||||
mbs_interface_ptr = NULL;
|
||||
vMBPortSetMode((UCHAR)MB_PORT_INACTIVE);
|
||||
return ESP_OK;
|
||||
}
|
||||
|
@ -654,6 +654,7 @@ vMBTCPPortDisable( void )
|
||||
xConfig.pxMbClientInfo[i] = NULL;
|
||||
}
|
||||
}
|
||||
free(xConfig.pxMbClientInfo);
|
||||
close(xListenSock);
|
||||
xListenSock = -1;
|
||||
vMBTCPPortRespQueueDelete(xConfig.xRespQueueHandle);
|
||||
|
Loading…
x
Reference in New Issue
Block a user