From 1724f8b4c02b08190eed1e5c4bc0f52c580c5f99 Mon Sep 17 00:00:00 2001 From: "Joseph C. Lehner" Date: Thu, 1 Aug 2019 20:58:04 +0200 Subject: [PATCH] Hopefully fix TFTP rollover hack --- tftp.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tftp.c b/tftp.c index 1e0dd73..ad24057 100644 --- a/tftp.c +++ b/tftp.c @@ -439,9 +439,13 @@ int tftp_put(struct nmrpd_args *args) * block #65535 - reported working on a Netgear D7000. */ block = UINT16_MAX; + pkt_mknum(tx + 2, block); freeze_block = true; errors = 0; printf("Transmitting rest of file as block %d.\n", block); + /* this forces transmission of the modified packet */ + timeouts = 1; + continue; } else { fprintf(stderr, "Protocol error; bailing out.\n"); ret = -1; -- 2.25.1