diff --git a/src/sbbs3/sbbsdefs.h b/src/sbbs3/sbbsdefs.h index da5ab20110433fc0225591faf9befbf17dcc1f93..21e8860306a3ee678029e60eeb2b0394e8369472 100644 --- a/src/sbbs3/sbbsdefs.h +++ b/src/sbbs3/sbbsdefs.h @@ -376,6 +376,7 @@ typedef enum { /* Values for xtrn_t.event */ #define QUOTEALL (1L<<12) /* Automatically quote all of msg */ #define QUOTENONE (1L<<13) /* Automatically quote none of msg */ #define XTRN_NATIVE (1L<<14) /* Native application */ +#define STRIPKLUDGE (1L<<15) /* Strip FTN Kludge lines from msg */ /* Bits in user.qwk */ #define QWK_FILES (1L<<0) /* Include new files list */ diff --git a/src/sbbs3/writemsg.cpp b/src/sbbs3/writemsg.cpp index 9d9426ae6d154e5b4eab28ca4c03cd91b388279d..20102172c20df912f8d62af4ef821a070ed4d063 100644 --- a/src/sbbs3/writemsg.cpp +++ b/src/sbbs3/writemsg.cpp @@ -373,12 +373,21 @@ bool sbbs_t::writemsg(char *fname, char *top, char *title, long mode, int subnum && cfg.xedit[useron.xedit-1]->misc&QUICKBBS) { fwrite(crlf,2,1,stream); i++; - continue; } + continue; + } + /* Expand LF to CRLF? */ if(buf[l]==LF && (!l || buf[l-1]!=CR) && useron.xedit && cfg.xedit[useron.xedit-1]->misc&EXPANDLF) { fwrite(crlf,2,1,stream); i++; - continue; } + continue; + } + /* Strip FidoNet Kludge Lines? */ + if(buf[l]==1 && useron.xedit + && cfg.xedit[useron.xedit-1]->misc&STRIPKLUDGE) { + while(buf[l]!=LF) l++; + continue; + } if(!(mode&(WM_EMAIL|WM_NETMAIL)) && (!l || buf[l-1]==LF) && buf[l]=='-' && buf[l+1]=='-' && buf[l+2]=='-'