Synchronet now requires the libarchive development package (e.g. libarchive-dev on Debian-based Linux distros, libarchive.org for more info) to build successfully.

Commit b25b425e authored by rswindell's avatar rswindell

New sub config property: n_pmode, P_* mode flags which are negated in the call

to putmg() when displaying messages in the sub on the terminal server.
E.g. to disable word-wrap for *all* messages displayed in a sub, set P_WORDWRAP
in sub_t.n_pmode.
parent 93da62d0
......@@ -91,7 +91,7 @@ bool sbbs_t::email(int usernumber, const char *top, const char *subj, long mode,
bputs(text[UnknownUser]);
return(false);
}
if((l&NETMAIL) && (cfg.sys_misc&SM_FWDTONET)) {
if((l&NETMAIL) && (cfg.sys_misc&SM_FWDTONET) && !(mode & WM_NOFWD)) {
getuserrec(&cfg,usernumber,U_NETMAIL,LEN_NETMAIL,str);
bprintf(text[UserNetMail],str);
if((mode & WM_FORCEFWD) || text[ForwardMailQ][0]==0 || yesno(text[ForwardMailQ])) /* Forward to netmail address */
......
......@@ -293,8 +293,10 @@ bool sbbs_t::show_msg(smb_t* smb, smbmsg_t* msg, long p_mode, post_t* post)
utf8_normalize_str(txt);
p_mode |= P_UTF8;
}
if(smb->subnum < cfg.total_subs)
if(smb->subnum < cfg.total_subs) {
p_mode |= cfg.sub[smb->subnum]->pmode;
p_mode &= ~cfg.sub[smb->subnum]->n_pmode;
}
putmsg(p, p_mode, msg->columns);
smb_freemsgtxt(txt);
if(column)
......
......@@ -69,6 +69,7 @@ typedef struct { /* Message sub board info */
maxmsgs, /* Max number of messages allowed */
maxcrcs; /* Max number of CRCs to keep */
int32_t pmode; /* printfile()/putmsg() mode flags */
int32_t n_pmode; /* set of negated pmode flags */
faddr_t faddr; /* FidoNet address */
} sub_t;
......
......@@ -565,7 +565,8 @@ BOOL read_msgs_cfg(scfg_t* cfg, char* error)
get_int(cfg->sub[i]->qwkconf,instream);
get_int(c,instream); // unused
get_int(cfg->sub[i]->pmode,instream);
for(j=0;j<24;j++)
get_int(cfg->sub[i]->n_pmode,instream);
for(j=0;j<22;j++)
get_int(n,instream);
}
cfg->total_subs=i;
......
......@@ -446,8 +446,9 @@ BOOL DLLCALL write_msgs_cfg(scfg_t* cfg, int backup_level)
c=0;
put_int(c,stream); // unused
put_int(cfg->sub[i]->pmode,stream);
put_int(cfg->sub[i]->n_pmode,stream);
n=0;
for(k=0;k<24;k++)
for(k=0;k<22;k++)
put_int(n,stream);
if(all_msghdr || (cfg->sub[i]->misc&SUB_HDRMOD && !no_msghdr)) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment