- Feb 21, 2019
- Feb 20, 2019
-
-
rswindell authored
(JS bbs.post_msg()): If the WM_QUOTE mode flag is *not* set, then it will auto- create the quote file (quotes.txt) and add the WM_QUOTE mode bit before calling sbbs_t::writemsg(). So if existing JS scripts call bbs.post_msg(..., WM_QUOTE) with a custom-created quote file (e.g. with msg tails), that'll still work as before (e.g. DDMsgReader.js). bbs.email() and bbs.netmail() now support an optional reply_header_object argument which works like bbs.post_msg(). These methods (and the underlying C++ methods: sbbs_t::email(), netmail(), inetmail(), all auto-create the quote file now, when the WM_QUOTE mode flag is *not* set. The auto-created quotes.txt now includes the plain-text version of MIME-encoded messages. the bbs.post_msg(), email(), and netmail() methods now all support reply header objects that came directly from bbs.get_msg_header() *or* copies of such header objects (but the auto-quoting feature won't work when supplied this type of header object). So if passed a header object returned from bbs.get_msg_header(), we can now use the message base (for auto-quoting) and the underlying msg storage directly (no JS parsing necessary). This is what the new js_GetMsgHeaderObjectPrivates() function is used for. js_ParseMsgHeaderObject() (and the underlying parse_header_object() function) now supports either an actual internally-generated msg header object (e.g. returned from bbs.get_msg_header()) or one that is a copy or hand-constructed. quotemsg() no longer tries to get a copy of the msg index/header. It shouldn't have to since we can now get to underlying msg storage in the js_msgbase.c via js_GetMsgHeaderObjectPrivates(). quotemsg() now reads only the plain-text portion of MIME-encoded messages. As part of this effort, I modernized the method prototypes using default argument values (e.g. WM_NONE for wm_mode arguments) and removed some extraneous WM_EMAIL and WM_NETMAIL specifications (these wm_mode flags are automatically added by the sbbs_t::email() and *netmail() functions). savemsg() now *does* support reply-IDs/thread-linkage via the additional 'remsg' argument (when non-NULL). Replaced some use of nulstr with NULL. Replaced more boilerplate SMB open code with calls to smb_open_sub().
-
- Feb 19, 2019
-
-
rswindell authored
used by js_post_msg() (the JS bbs.post_msg() method when used with the reply_header object argument) - the private data attached to a message header object is of type privatemsg_t, not private_t. This caused the dereferences of and assignments to p->smb_result in parse_header_object() to corrupt the privatemsg_t->msg memory causing heap corruption (caught on Windows debug builds in js_get_msg_header_finalize()) and stack faults (caught on Linux-gcc in parse_recipient_object()). This one was hard to find. <whew!>
-
rswindell authored
I noticed that printable ctrl chars (e.g. 0x18 and 0x19) were not causing the current column position to increment, so that got me looking at this code and wondering why the LF/FF checking was outside the if(!outchar_esc) condition and being executed when CON_R_ECHO is off. So now, using a switch statement, it's cleaner and all the printable ctrl chars move the current column position correctly.
-
rswindell authored
When the WM_QUOTE mode flag is set and the 'remsg' is specified, the original message will quoted (excluding message tails, using the proper word-wrapping). If the quote file already exists before calling postmsg()/bbs.post_msg(), it will be over-written. This allows JS script to initiate reply-posts with quoted text without having to create their own quotes file. It also means there's no need to call sbbs_t::quotemsg() before calling sbbs_t::postmsg(). sbbs_t::quotemsg() now takes an smb_t* arg (stop using the sbbs_t 'global' smb) and now returns bool.
-
rswindell authored
Renamed js_postmsg() -> js_post_msg() for good measure.
-
rswindell authored
-
- Feb 18, 2019
- Feb 17, 2019
-
-
rswindell authored
designator.
-
rswindell authored
Only treat an invalid QWK msg block count (<2) as an error if there is more than one msg header in the packet (stop saving so many worthless data/file/*.rep.*.bad files).
-
rswindell authored
-
rswindell authored
file lists during events.
-
rswindell authored
"read %u message scan cfg/pointers in %lu ms" The message pointer performance problems were resolved a long time ago now and this is just noise in the logs.
-
rswindell authored
reported as "Duplicate index offset", so overlapping headers means the index offset must not be an exact duplicate, so we don't report the same corrupt message parameter (its offset into the header file) 2 different ways.
-
rswindell authored
is 0 (logic moved from sbbs_t::postmsg()).
-
rswindell authored
as it is easy for a sysop to accidentally hit [D]elete and not realize it.
-
rswindell authored
-
rswindell authored
packets.
-
rswindell authored
So I created a single add_msg_ids() function (mostly migrated from postmsg.cpp) to make this incredibly easy so any/everywhere that adds a message to a message base should be able to call it. This function also creates reply-IDs (when relevant) and program ID (Fido-PID) header fields: - FIDOPID (always) - FIDOMSGID (if an echomail post) - FIDOREPLYID (if an echomail reply-post) - RFC822MSGID (always) - RFC822REPLYID (if a reply)
-
rswindell authored
If the user.dat file is already opened in deny-none mode (as is the norm), another process (e.g. useredit.exe) cannot simultaneously open it in exclusive mode.
-
- Feb 16, 2019
-
-
rswindell authored
the read buffer may be utilized more efficiently if you do *not* perform an (unnecessary) seek operation just before the read. By eliminating unnecessary seeks in smb_getmsgidx() and smb_getmsghdr(), I was able to reduce the time required to load 9000+ index and header records over a network (Samba/CIFS) share from 15+ seconds to less than 5.
-
rswindell authored
(blank names or internal codes) from the total saved to xtrn.cnf.
-
rswindell authored
read the entire index file in a single read operation
-
rswindell authored
This has not actually been an observed problem, but I just realized while working on smb optimizations that this condition would not be reported by chksmb.
-
- Feb 15, 2019
-
-
rswindell authored
- loginAttemptListCount() - loginAttemptListClear() - loginAttempts() Now returns 0 on list lock faliure: loginFailure() and loginBanned().
-
rswindell authored
events when not in "appy-time".
-
rswindell authored
So now if you need to clear the failed-login/temp-ban list, just 'touch /sbbs/ctrl/clear' Other changes to the semfiles: The terminal server is now identified as "term" rather than "telnet" in the (optional) server/protocol specific semfile naming. Removed support for the old telnet.rec semfile (long deprecated).
-
rswindell authored
-
rswindell authored
-
rswindell authored
email/netmail messages. Does *not* support the "From:" kludge. I know this function needs need to be completely replaced and it's silly to have QWK kludge parsing logic in multiple places, but ugh, I didn't want to rewrite this just yet.
-
rswindell authored
sub-menus.
-
rswindell authored
internal code suffixes or grp/lib internal code prefixes. More strcpy->SAFECOPY and sprintf -> SAFEPRINTF replacements. More use of uifcYesNoOpts.
-
rswindell authored
if any sub-boards or directories have *blank* names or internal code suffixes (a sign of a corrupted configuration), exclude them from the saved subs/dirs automatically. I'm not sure how this can happen (use of cnflib.js?) - but running "scfg -f" (force save) should fix this situation. For Android8675.
-
- Feb 14, 2019
-
-
rswindell authored
DOOR.ID file created by Synchronet.
-
rswindell authored
plain-text portion (only) for MIME-encoded messages (emails). If/when there are ever QWK readers that support MIME-decoding, I'll make this behavior configurable. :-) When passing mail between QWKnet nodes, leave the original MIME-encoding in tact (if there is any).
-
rswindell authored
If the modify callback function returned a pointer *within* the list item's allocated buffer, the strcpy() would copy from potentialy free'd memory as realloc may change the location of the heap buffer when resizing. Fixed by allocating a copy of the returned pointer before freeing the original list item buffer and then just assign the allocated pointer (no copying needed). This likely will result in more heap fragmentation for modified list items are now newly-allocated buffers rather than reallocated existing buffers but the other option would have been to allocate a temporary copy of the string before reallocating and then copying and that would've been a lot more overhead than with this approach. This likely fixes any crashes seen in recent revs of v3.17c (e.g. when imported QWK or REP packets and text/*.can and the twitlist.cfg are parsed). The sighting on Vertrauen was only in the Windows build and appeared when importing QWK/REP packets.
-