Skip to content
Snippets Groups Projects
Commit 39e3b09a authored by rswindell's avatar rswindell
Browse files

Initializes xmodem/zmodem error and status file pointers.

parent 8e88af73
No related branches found
No related tags found
No related merge requests found
......@@ -403,10 +403,14 @@ void send_files(char** fname, uint fnames, FILE* log)
memset(&xm,0,sizeof(xm));
xm.sock=sock;
xm.mode=mode;
xm.errfp=errfp;
xm.statfp=statfp;
memset(&zm,0,sizeof(zm));
zm.sock=sock;
zm.mode=mode;
zm.errfp=errfp;
zm.statfp=statfp;
zm.n_files_remaining = total_files;
zm.n_bytes_remaining = total_bytes;
......@@ -597,7 +601,7 @@ void send_files(char** fname, uint fnames, FILE* log)
if(!t) t=1; /* t is time so far */
cps=(uint)((block_num*(long)block_size)/t); /* cps so far */
if(!cps) cps=1;
l=fsize/cps; /* total transfer est time */
l=fsize/cps; /* total transfer est time */
l-=t; /* now, it's est time left */
if(l<0) l=0;
b=num_blocks(fsize,block_size);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment