mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 00:32:25 -04:00
Fix core dump when server fails to respond.
Reviewed by: imp
This commit is contained in:
parent
bc96d3d17a
commit
a1ec94b88d
1 changed files with 4 additions and 1 deletions
|
|
@ -229,7 +229,10 @@ recvfile(int peer, char *port, int fd, char *name, char *mode)
|
|||
/* Otherwise it is a fatal error */
|
||||
break;
|
||||
}
|
||||
|
||||
if (i == 12) {
|
||||
printf("Transfer timed out.\n");
|
||||
return;
|
||||
}
|
||||
if (rp->th_opcode == ERROR) {
|
||||
tftp_log(LOG_ERR, "Error code %d: %s", rp->th_code, rp->th_msg);
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in a new issue