From f73c9ad24ef60ddd3b49b382520a85d02c0fdb33 Mon Sep 17 00:00:00 2001 From: rswindell <> Date: Sun, 4 Nov 2001 00:49:01 +0000 Subject: [PATCH] Changed protocol 'cd' arg to bool. --- src/sbbs3/email.cpp | 2 +- src/sbbs3/execfunc.cpp | 4 ++-- src/sbbs3/fido.cpp | 2 +- src/sbbs3/listfile.cpp | 2 +- src/sbbs3/netmail.cpp | 2 +- src/sbbs3/qwk.cpp | 6 +++--- src/sbbs3/readmail.cpp | 3 +-- src/sbbs3/sbbs.h | 2 +- src/sbbs3/upload.cpp | 2 +- 9 files changed, 12 insertions(+), 13 deletions(-) diff --git a/src/sbbs3/email.cpp b/src/sbbs3/email.cpp index 55b3e5ea42..ab7376553f 100644 --- a/src/sbbs3/email.cpp +++ b/src/sbbs3/email.cpp @@ -141,7 +141,7 @@ bool sbbs_t::email(int usernumber, char *top, char *subj, long mode) && chk_ar(cfg.prot[x]->ar,&useron)) break; if(x<cfg.total_prots) /* This should be always */ - protocol(cmdstr(cfg.prot[x]->ulcmd,str2,nulstr,NULL),0); } + protocol(cmdstr(cfg.prot[x]->ulcmd,str2,nulstr,NULL),true); } l=flength(str2); if(l>0) bprintf(text[FileNBytesReceived],title,ultoac(l,tmp)); diff --git a/src/sbbs3/execfunc.cpp b/src/sbbs3/execfunc.cpp index da3205b815..15225db25b 100644 --- a/src/sbbs3/execfunc.cpp +++ b/src/sbbs3/execfunc.cpp @@ -648,7 +648,7 @@ int sbbs_t::exec_function(csi_t *csi) if(cfg.prot[i]->mnemonic==ch && chk_ar(cfg.prot[i]->ar,&useron)) break; if(i<cfg.total_prots) { - protocol(cmdstr(cfg.prot[i]->dlcmd,csi->str,csi->str,str),0); + protocol(cmdstr(cfg.prot[i]->dlcmd,csi->str,csi->str,str),false); autohangup(); } return(0); @@ -672,7 +672,7 @@ int sbbs_t::exec_function(csi_t *csi) if(cfg.prot[i]->mnemonic==ch && chk_ar(cfg.prot[i]->ar,&useron)) break; if(i<cfg.total_prots) { - protocol(cmdstr(cfg.prot[i]->ulcmd,csi->str,csi->str,str),0); + protocol(cmdstr(cfg.prot[i]->ulcmd,csi->str,csi->str,str),true); autohangup(); } return(0); diff --git a/src/sbbs3/fido.cpp b/src/sbbs3/fido.cpp index 26536d9b4e..496dc3a1da 100644 --- a/src/sbbs3/fido.cpp +++ b/src/sbbs3/fido.cpp @@ -252,7 +252,7 @@ bool sbbs_t::netmail(char *into, char *title, long mode) && chk_ar(cfg.prot[x]->ar,&useron)) break; if(x<cfg.total_prots) /* This should be always */ - protocol(cmdstr(cfg.prot[x]->ulcmd,subj,nulstr,NULL),0); } + protocol(cmdstr(cfg.prot[x]->ulcmd,subj,nulstr,NULL),true); } l=flength(subj); if(l>0) bprintf(text[FileNBytesReceived],fname,ultoac(l,tmp)); diff --git a/src/sbbs3/listfile.cpp b/src/sbbs3/listfile.cpp index fc5b168c1d..430cd6e7fa 100644 --- a/src/sbbs3/listfile.cpp +++ b/src/sbbs3/listfile.cpp @@ -1247,7 +1247,7 @@ int sbbs_t::listfileinfo(uint dirnum, char *filespec, long mode) thisnode.aux=(tm->tm_hour*60)+tm->tm_min; putnodedat(cfg.node_num,&thisnode); /* calculate ETA */ start=time(NULL); - j=protocol(cmdstr(cfg.prot[i]->dlcmd,path,nulstr,NULL),0); + j=protocol(cmdstr(cfg.prot[i]->dlcmd,path,nulstr,NULL),false); end=time(NULL); if(cfg.dir[f.dir]->misc&DIR_TFREE) starttime+=end-start; diff --git a/src/sbbs3/netmail.cpp b/src/sbbs3/netmail.cpp index 0f7d921a54..e91d7698ce 100644 --- a/src/sbbs3/netmail.cpp +++ b/src/sbbs3/netmail.cpp @@ -130,7 +130,7 @@ bool sbbs_t::inetmail(char *into, char *subj, long mode) && chk_ar(cfg.prot[x]->ar,&useron)) break; if(x<cfg.total_prots) /* This should be always */ - protocol(cmdstr(cfg.prot[x]->ulcmd,str2,nulstr,NULL),0); } + protocol(cmdstr(cfg.prot[x]->ulcmd,str2,nulstr,NULL),true); } l=flength(str2); if(l>0) bprintf(text[FileNBytesReceived],title,ultoac(l,tmp)); diff --git a/src/sbbs3/qwk.cpp b/src/sbbs3/qwk.cpp index 3a4dd8ef26..840e50032b 100644 --- a/src/sbbs3/qwk.cpp +++ b/src/sbbs3/qwk.cpp @@ -575,7 +575,7 @@ void sbbs_t::qwk_sec() padfname(tmp2,fd.name); sprintf(str,"%sBATCHDN.LST",cfg.node_dir); sprintf(tmp2,"%sBATCHUP.LST",cfg.node_dir); - j=protocol(cmdstr(cfg.prot[i]->bicmd,str,tmp2,NULL),0); + j=protocol(cmdstr(cfg.prot[i]->bicmd,str,tmp2,NULL),true); batdn_total=batup_total=0; if(cfg.prot[i]->misc&PROT_DSZLOG) { if(!checkprotlog(&fd)) { @@ -672,7 +672,7 @@ void sbbs_t::qwk_sec() sprintf(str,"%s%s.qwk",cfg.temp_dir,cfg.sys_id); sprintf(tmp2,"%s.qwk",cfg.sys_id); padfname(tmp2,fd.name); - j=protocol(cmdstr(cfg.prot[i]->dlcmd,str,nulstr,NULL),0); + j=protocol(cmdstr(cfg.prot[i]->dlcmd,str,nulstr,NULL),false); if(cfg.prot[i]->misc&PROT_DSZLOG) { if(!checkprotlog(&fd)) { last_ns_time=ns_time; @@ -748,7 +748,7 @@ void sbbs_t::qwk_sec() if(i>=cfg.total_prots) /* This shouldn't happen */ continue; sprintf(str,"%s%s.rep",cfg.temp_dir,cfg.sys_id); - protocol(cmdstr(cfg.prot[i]->ulcmd,str,nulstr,NULL),0); + protocol(cmdstr(cfg.prot[i]->ulcmd,str,nulstr,NULL),true); unpack_rep(); delfiles(cfg.temp_dir,ALLFILES); //autohangup(); diff --git a/src/sbbs3/readmail.cpp b/src/sbbs3/readmail.cpp index c05daf7ca0..5b5f995a4b 100644 --- a/src/sbbs3/readmail.cpp +++ b/src/sbbs3/readmail.cpp @@ -257,8 +257,7 @@ void sbbs_t::readmail(uint usernumber, int which) && chk_ar(cfg.prot[i]->ar,&useron)) break; if(i<cfg.total_prots) { - j=protocol(cmdstr(cfg.prot[i]->dlcmd,str2,nulstr - ,NULL),0); + j=protocol(cmdstr(cfg.prot[i]->dlcmd,str2,nulstr,NULL),false); if((cfg.prot[i]->misc&PROT_DSZLOG && checkprotlog(&fd)) || (!(cfg.prot[i]->misc&PROT_DSZLOG) && !j)) { diff --git a/src/sbbs3/sbbs.h b/src/sbbs3/sbbs.h index 2932cfba6b..3d6cc7cf3e 100644 --- a/src/sbbs3/sbbs.h +++ b/src/sbbs3/sbbs.h @@ -546,7 +546,7 @@ public: /* download.cpp */ void downloadfile(file_t* f); void notdownloaded(ulong size, time_t start, time_t end); - int protocol(char *cmdline, int cd); + int protocol(char *cmdline, bool cd); void seqwait(uint devnum); void autohangup(void); bool checkprotlog(file_t* f); diff --git a/src/sbbs3/upload.cpp b/src/sbbs3/upload.cpp index 1affdbd18a..7fd15a4763 100644 --- a/src/sbbs3/upload.cpp +++ b/src/sbbs3/upload.cpp @@ -470,7 +470,7 @@ void sbbs_t::upload(uint dirnum) break; if(i<cfg.total_prots) { start=time(NULL); - protocol(cmdstr(cfg.prot[i]->ulcmd,str,nulstr,NULL),0); + protocol(cmdstr(cfg.prot[i]->ulcmd,str,nulstr,NULL),true); end=time(NULL); if(!(cfg.dir[dirnum]->misc&DIR_ULTIME)) /* Don't deduct upload time */ starttime+=end-start; -- GitLab