mirror of
https://github.com/apache/nuttx-apps.git
synced 2026-08-03 13:19:03 +00:00
netutils/ftpd: fix hardfault when initial socket, bind or listen fails
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
This commit is contained in:
parent
6aca60133c
commit
5c8d6934a5
1 changed files with 4 additions and 1 deletions
|
|
@ -4496,7 +4496,10 @@ void ftpd_close(FTPD_SESSION handle)
|
|||
DEBUGASSERT(handle);
|
||||
|
||||
server = (struct ftpd_server_s *)handle;
|
||||
ftpd_account_free(server->head);
|
||||
if (server->head != NULL)
|
||||
{
|
||||
ftpd_account_free(server->head);
|
||||
}
|
||||
|
||||
if (server->sd >= 0)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue