diff --git a/src/sbbs3/echocfg.c b/src/sbbs3/echocfg.c index 3ca270a06e85b71f9f55ef83dfdd0c8491fcd1f1..b1c7e0383eda8c82d3b5e411f304aa86f8c72ff1 100644 --- a/src/sbbs3/echocfg.c +++ b/src/sbbs3/echocfg.c @@ -8,7 +8,7 @@ * @format.tab-size 4 (Plain Text/Source Code File Header) * * @format.use-tabs true (see http://www.synchro.net/ptsc_hdr.html) * * * - * Copyright 2011 Rob Swindell - http://www.synchro.net/copyright.html * + * Copyright 2012 Rob Swindell - http://www.synchro.net/copyright.html * * * * This program is free software; you can redistribute it and/or * * modify it under the terms of the GNU General Public License * @@ -1180,6 +1180,7 @@ int main(int argc, char **argv) if(misc&TRUNC_BUNDLES) fprintf(stream,"TRUNC_BUNDLES\n"); + fprintf(stream,"SYSOP_ALIAS %s\n", cfg.sysop_alias); if(cfg.areafile[0]) fprintf(stream,"AREAFILE %s\n",cfg.areafile); if(cfg.logfile[0]) diff --git a/src/sbbs3/rechocfg.c b/src/sbbs3/rechocfg.c index 524686470e0c454e0eb883941dc3afa58576230b..8882b1a9710105b3fba03ecd4025dbfebb758ffb 100644 --- a/src/sbbs3/rechocfg.c +++ b/src/sbbs3/rechocfg.c @@ -200,6 +200,7 @@ void read_echo_cfg() cfg.log=LOG_DEFAULTS; cfg.log_level=LOG_INFO; cfg.check_path=TRUE; + SAFECOPY(cfg.sysop_alias,"SYSOP"); while(1) { if(!fgets(str,256,stream)) @@ -219,6 +220,10 @@ void read_echo_cfg() SKIPCODE(p); /* Skip code */ SKIPCTRLSP(p); /* Skip white space */ + if(!stricmp(tmp,"SYSOP_ALIAS")) { + SAFECOPY(cfg.sysop_alias, p); + continue; + } if(!stricmp(tmp,"PACKER")) { /* Archive Definition */ if((cfg.arcdef=(arcdef_t *)realloc(cfg.arcdef ,sizeof(arcdef_t)*(cfg.arcdefs+1)))==NULL) { diff --git a/src/sbbs3/sbbsecho.c b/src/sbbs3/sbbsecho.c index 7fe96964ba2328cdcb5c8213aef87652cc65deb3..aca15b0643409bfb7b0d649e533877f05dbd554d 100644 --- a/src/sbbs3/sbbsecho.c +++ b/src/sbbs3/sbbsecho.c @@ -3461,7 +3461,7 @@ int import_netmail(char *path,fmsghdr_t hdr, FILE *fidomsg) } usernumber=atoi(hdr.to); - if(!stricmp(hdr.to,"SYSOP")) /* NetMail to "sysop" goes to #1 */ + if(cfg.sysop_alias[0] && stricmp(hdr.to,cfg.sysop_alias)==0) /* NetMail to configured SYSOP_ALIAS goes to user #1 */ usernumber=1; if(!usernumber && match<scfg.total_faddrs) usernumber=matchname(hdr.to); diff --git a/src/sbbs3/sbbsecho.h b/src/sbbs3/sbbsecho.h index 3131772891bb8cf1336b2577bf8653aa71da5bbe..62f433b5bafaa4db3fc2502315e84b0d59558375 100644 --- a/src/sbbs3/sbbsecho.h +++ b/src/sbbs3/sbbsecho.h @@ -221,7 +221,8 @@ typedef struct { ,outbound[82] /* Outbound directory */ ,areafile[128] /* AREAS.BBS path/filename */ ,logfile[128] /* LOG path/filename */ - ,cfgfile[128]; /* Configuration path/filename */ + ,cfgfile[128] /* Configuration path/filename */ + ,sysop_alias[FIDO_NAME_LEN]; ulong maxpktsize /* Maximum size for packets */ ,maxbdlsize /* Maximum size for bundles */ ,log /* What do we log? */