in tftpboot, if ack was already sent previously for this
packet, don't send again.
Fixes:
cc6b87ecaa96 ("net: tftp: Add client support for RFC 7440")
Reported-by: Suneel Garapati <suneelglinux@gmail.com>
Signed-off-by: Ramon Fried <rfried.dev@gmail.com>
Tested-by: Suneel Garapati <suneelglinux@gmail.com>
Tested-by: Oliver Graute <oliver.graute@kococonnector.com>
break;
}
+ if (len < tftp_block_size) {
+ tftp_send();
+ tftp_complete();
+ break;
+ }
+
/*
* Acknowledge the block just received, which will prompt
* the remote for the next one.
tftp_send();
tftp_next_ack += tftp_windowsize;
}
-
- if (len < tftp_block_size) {
- tftp_send();
- tftp_complete();
- }
break;
case TFTP_ERROR: