From e369d44fcb4dc01a0b373dfaf77b7f2af506d75a Mon Sep 17 00:00:00 2001 From: rswindell <> Date: Sun, 12 Jul 2009 16:51:29 +0000 Subject: [PATCH] Bug-fix: wasn't using ZCRCE for last subpacket. --- src/sbbs3/zmodem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sbbs3/zmodem.c b/src/sbbs3/zmodem.c index d6d4ad0423..cf0043de62 100644 --- a/src/sbbs3/zmodem.c +++ b/src/sbbs3/zmodem.c @@ -1443,7 +1443,7 @@ int zmodem_send_from(zmodem_t* zm, FILE* fp, uint32_t pos, uint32_t* sent) buf_sent=0; } - if(zm->current_file_pos >= zm->current_file_size || n==0) /* can't use feof() here! */ + if(zm->current_file_pos+n >= zm->current_file_size || n==0) /* can't use feof() here! */ type = ZCRCE; /* Note: No support for sending ZCRCQ data sub-packets here */ -- GitLab