Skip to content
Snippets Groups Projects
  1. Dec 01, 2021
    • Rob Swindell's avatar
      Fix some FOSSIL functions · c75f5aa3
      Rob Swindell authored
      Function 0Ch (peek) never worked correctly (character was not returned in AX); I guess nothing uses this function (?).
      
      Function 01h (transmit char w/wait) now will set the timeout flag (0x8000) in the AX if the VDD_WRITE function fails (returns value other than 1).
      
      Optimize Function 18h (read block) - no need for the extra VDD_STATUS call.
      
      Use newly defined FOSSIL macros instead of magic numbers of port status bits.
      
      Log the git branch/hash values to the Windows debug log (via sbbsexec.dll).
      c75f5aa3
    • Rob Swindell's avatar
      The sem_wait() call was just a bad idea after-all · 24eddf1e
      Rob Swindell authored
      The sem_wait() call from vdd_read() that was fixed in the previous commit to this file was a bad idea to begin with:
      There is (often) not a 1:1 ratio of bytes in the receive ring buffer and the semaphore count, so we'd often halt here waiting for the semaphore to be signaled even though there were still characters in the receive buffer. This caused (new) stalls/hangs in keyboard input in DOS door games. We didn't see this previously because the sem_wait() call just didn't work (wrong semaphore pointer value).
      
      Now, call sem_trywait_block() in vdd_read(), but only if the RingBufRead() returned 0 (no bytes read) and even then, only block/wait for a maximum of 30 seconds (same as X00 FOSSIL driver). This blocking behavior is specified for FOSSIL function 02h (Get received character with wait) and would not have worked previous to the previous "fix", so now we have that corrected behavior too. The FTSC spec says the wait is indefinite, but I think a 30 second timeout (ala X00) is more reasonable.
      
      Log the git brach/hash instead of the old CVS revision.
      
      GetMailSlotInfo() apparently always fails on Windows 7 with error 87 (even using Microsoft's own sample code), so lower the log message severity of that failure from ERR to DEBUG. Apparently this is pretty harmless anyway as nothing really needs the write-mailslot status. <shrug>
      24eddf1e
    • Rob Swindell's avatar
      Add a debug line when wrapping split-screen chat lines. · d8cbf926
      Rob Swindell authored
      Is this the point when the lost chars problem happens?
      d8cbf926
  2. Nov 30, 2021
  3. Nov 24, 2021
    • Rob Swindell's avatar
      Implement FOSSIL function 0Dh (Keyboard read without wait) · 76872671
      Rob Swindell authored
      As a work around for TradeWars 2 (v11.14 and v11.20) FOSSIL support:
      This door game would never call the FOSSIL "get received character"
      function (02h) . But I did notice that it was calling the "Keyboard
      read" functions. I never implemented the "Keyboard read" functions
      (figured the door game could read the keyboard itself if it wanted to),
      but appparently TW2 won't ever read the COM port (using function 02h)
      unless the Keyboard read function returns AX=0xFFFF (no keyboard data
      available). So now, I just do that and TW2 works (with FOSSIL I/O).
      
      Incremented the revision to 26.
      Logging the Git branch/hash and other helpful FOSSIL-debug stuff now.
      76872671
    • Rob Swindell's avatar
      Continuation of previous commit (support for UART-only doors on Windows) · 9c4ad56c
      Rob Swindell authored
      Needed the actually mapping of XTRN_UART -> EX_UART mode flag here.
      9c4ad56c
  4. Nov 23, 2021
    • Rob Swindell's avatar
      Allow FOSSIL mode of the Win32 virtual UART/FOSSIL driver to be disabled · 2bbd3bca
      Rob Swindell authored
      When configuring an external program, a Win32 sysop can now choose to *only* enable the virtual UART (and not the FOSSIL driver) feature of the Synchronet virtual UART/FOSSIL driver (dosxtrn.exe/sbbsexec.dll). Some programs (e.g. TradeWars 2) will always use the FOSSIL driver if one is detected and in order to force the use of COM/UART driver for I/O (if that is desired), then one must disable the FOSSIL driver. It's a rare use case, but I can see the potential need.
      
      Renamed the "Intercept I/O" option in SCFG to "I/O Method" and make it clear that "Socket" (for native programs) and "FOSSIL or UART" (for 16-bit DOS programs) is the default method (what was previously identified as "No" I/O Interception).
      
      If a sysop want to disable the virtual UART support (on Win32, e.g. so *only* FOSSIL is available to one or all DOS programs), they do that via their sbbsexec.ini file.
      2bbd3bca
    • Rob Swindell's avatar
      38e6ed3f
  5. Nov 19, 2021
  6. Nov 18, 2021
    • Rob Swindell's avatar
      Add text.dat lines for "All" and the List key ('L'), used in quoting · 9513bdba
      Rob Swindell authored
      The internal line editor's quoting feature add some hard-coded strings ("Done" and "All") and the (L)ist key was hard-coded. Use the text.dat string (new and pre-existing) for these now.
      
      Also, use the new sbbs_t *_key() methods for referencing the configured key bindings (via text.dat) for these common key-stroke commands.
      Convert the text.dat strings for keys (e.g. YNQP) to uppercase always as well.
      9513bdba
    • Rob Swindell's avatar
      Make msg/file scan configuration prompts and keys configurable · 6d3589a6
      Rob Swindell authored
      For localization purposes, no more hard-coded text strings or characters in the new-file and file scan configuration menus.
      
      This change fixes issue 232.
      
      A Hungarian sysop also requested this change via Facebook not long ago.
      6d3589a6
    • Rob Swindell's avatar
      Don't use time_t in scfg_t definition · a3649cc6
      Rob Swindell authored
      sbbsctrl.exe is built with Borland C++ still which only has a 32-bit time_t, so to keep the scfg_t definition compatible between MSVC and Borland builds, use time32_t (32-bit time_t) values only.
      
      This fixes the reported sbbsctrl.exe error:
      Error loading configuration
      cfg->size (23944) != sizeof(scfg_t) (23952)
      
      Introduced in commit b76b5318.
      Reported via DOVE-Net by  Daryl Stout (TBOLT), confirmed by Nightfox (DIGDIST).
      a3649cc6
  7. Nov 17, 2021
    • Rob Swindell's avatar
      Include twit-listed sender name in quotes in log message · 76f0ae79
      Rob Swindell authored
      Since mail server log messages have their white-space condensed, it was not obvious why some sender's name would match a twitlist.cfg line that filters names beginning with a space: "\ *" because the initial space of the sender's name was condensed/combined with space before it in the log message.
      76f0ae79
  8. Nov 16, 2021
    • Rob Swindell's avatar
      Initialize time zone variable (zone) · bf82b184
      Rob Swindell authored
      As found and reported by Talisam author, apam (HAPPYLND).
      
      sscanf() won't initialize the buffer of the argument passed if the format string is not matched, so when there was no hexadecimal/SMB timezone value, the timezone specified in the ISO date/time string (if any) would be overwritten with 0, converted from the uninitialized 'zone' variable (unlikely to be valid hex-ASCII chars). Thanks apam!
      bf82b184
    • Rob Swindell's avatar
      Add support for "name@address" syntax in twitlist.cfg · d3c5cccd
      Rob Swindell authored
      where "address" is a QWKnet ID or path or a FidoNet originating address. Wildcards can be used (e.g. "*@VERT").
      
      For Trikester.
      d3c5cccd
    • Rob Swindell's avatar
      Add command-line specifier for user's real name (auto-quoted) · 31b5229d
      Rob Swindell authored
      %+ will now expand to the current user's real name, automatically enclosed in quotes if it contains any spaces.
      31b5229d
  9. Nov 12, 2021
    • Rob Swindell's avatar
      Generate a MSGID kludge for netmail messages created by SBBSecho · 96712a1c
      Rob Swindell authored
      The "serialno" field is a bad/naive one (a time_t value), but this is really just an experiment for Ragnarok to see if this fixes issue #306 (with hotdoged receiving AreaFix responses/notices).
      96712a1c
    • Rob Swindell's avatar
      Fix sbbsfile.nam contents: contained file's description instead of name · 530a9c54
      Rob Swindell authored
      Found during review of previous commit.
      Introduced as part of the new file base branch merge (commit 925e3b0a).
      530a9c54
    • Rob Swindell's avatar
      Don't write uploaded filename and description to env variables · a869fc69
      Rob Swindell authored
      Environment variables are shared among all threads of a process (e.g. all nodes of a instance of sbbs), so this scheme of passing the uploaded filename and description to an external file tester (upload processor) via environment variables has always been fraught with the possibility of failure or flakiness in Synchronet v3. Since I very much doubt that any upload processor is actually using this scheme, just remove it. Upload processors can and should)use the sbbsfile.nam and sbbsfile.des text files created in the node directory instead.
      a869fc69
    • Rob Swindell's avatar
      Log an error and exit immediately when a local linked-node is configured · b0df2d4e
      Rob Swindell authored
      When a linked-node (in echocfg->Linked Nodes) contains one of the local system's FTN addresses, display/log an error and exit immediately, e.g.:
      Configuration ERROR: Linked node #20 is your own address: 1:103/705
      
      I'd perform this check in EchoCfg, but:
      1. echocfg doesn't read the BBS's configuration files (where the local FTN addresses are configured), and
      2. some sysops just directly edit their sbbsecho.ini file
      b0df2d4e
  10. Nov 08, 2021
  11. Oct 23, 2021
    • Rob Swindell's avatar
      Fix segfault after batch-upload when no "uploads" dir specified · 1f93fd53
      Rob Swindell authored
      When there's no "uploads" directory configured by the sysop, cfg.upload_dir will be set to INVALID_DIR, which cannot be used as an index into cfg.dir[] to determine if the time used for uploading the files should be "given back" to the user.
      
      In v3.18, we used the first file in the upload queue, if there was one, else fell back to the "uploads" dir (which had to have been defined if there were no files in the queue). So this illegal array indexing was a regression in v3.19.
      
      Reported by Zoltán Gábor on Facebook
      1f93fd53
  12. Oct 07, 2021
    • Rob Swindell's avatar
      When packing netmail (stored messages), don't discard non-zero zones · c2dca953
      Rob Swindell authored
      As reported by Ragnarok (DOCKSUD) via DOVE-Net, when packing (packetizing) netmail messages, the source and destination zones from the netmail header were discarded (since they are defined as "optional" in FTS-1) and the zone values were replaced with the system's primary/default zone number. If the netmail message included an INTL kludge, the source and destination zone values would be parsed from that kludge line and this issue would not be noticed. 
      
      So the fix is: Only if the netmail message header contains a source or destination zone number of 0, replace that zone with the system's primary/default zone number. As before, the INTL kludge zone information can override the header fields.
      
      Also, there's no reason to force the point numbers from the header to zero, since if they were not valid (e.g. "fill" in the original FTS-1 specification), they would be already zero. So use the source and destination point numbers, as is, from the netmail header too (with the FMPT and TOPT kludge override support left in-tact).
      c2dca953
    • Rob Swindell's avatar
      Print "All good" or "All bad" when trying to recover or split a packet · 363fc29a
      Rob Swindell authored
      At Nelgin's suggestion, if all the messages in a packet are either good or bad, say so (since no .good or .bad file will be generated in that case).
      363fc29a
  13. Oct 06, 2021
    • Rob Swindell's avatar
      New @-code: !x to perform Ctrl-A style terminal/attribute control · 6b6383da
      Rob Swindell authored
      Most Ctrl-A code terminal/attribute effects can now be invoked via @!x@ where x is one or more Ctrl-A sequence operands (e.g. @!B@ to set the current attribute to blue, @!P@ to pause the terminal). Multiple attribute codes may be specified in a single @!x@ sequence. Both upper and lowercase attribute codes are supported. The "^A@" sequence is not supported, but there's already an @-code to perform the equivalent operation ("SHOW:20").
      
      Rationale: when using PabloDraw to edit display (e.g. .msg) files, there was no easy way to explicitly clear (set to "normal") the current attributes at the end of a line of text. If that line of text contained a background color and the line caused the terminal to scroll, that background color would fill the next/new line resulting in some potential undesirable effects. There are 2 common solutions to this problem: either clear the screen before displaying the file (not always desirable) or clear the attributes at the end of the line (before the CR/LF). This can now be achieved by adding a @!N@ (the equivalent of Ctrl-AN for "normal" attributes) to the end of a line. There's no way to insert custom Ctrl-A sequences or other way to force PabloDraw to clear the attributes at the end of a line, that I found.
      
      I chose the '!' character because it's (on my keyboard anyway) the Shift-1 key and Ctrl-A is ASCII 1. I considered a sequence such as @A:x@, but that's one more character and since this sequence usually won't display anything, a shorter sequence is likely preferred. For the shortest-possible sequence, use Ctrl-A sequences instead. However, for many consecutive Ctrl-A sequences, the @-code equivalent might actually end up being shorter(!). @-codes aren't support in as many places in Synchronet where Ctrl-A codes are supported (for security reasons), so it's not like this is going to replace the use of Ctrl-A codes everywhere.
      6b6383da
    • Rob Swindell's avatar
      New @-codes SEX and GENDERS · 67bb599a
      Rob Swindell authored
      SEX is the user's sex/gender
      GENDERS is the list of system-supported genders for new users to choose from.
      67bb599a
    • Rob Swindell's avatar
      Don't append the stale static string in fmsgattr_str() · 2fae58e1
      Rob Swindell authored
      When this function was called multiple times (e.g. multiple messages in a pkt),
      it would keep appending to the current (static) string, eventually overflowing
      the buffer and corrupting the stack. Although reported in pktdump, it could
      have also happened with fmsgdump if passed multiple stored message (.msg) files.
      
      Fixes #295 reported by Nelgin
      2fae58e1
  14. Sep 25, 2021
    • Rob Swindell's avatar
      Allow sysop to configure new user gender options (not just M/F) · 1ca401eb
      Rob Swindell authored
      Up to 40 characters can be configured by the sysop for gender options.
      The default choice/configuration is now: "M/F/X" (not just "M/F")
      New @-code: GENDERS
      text.dat EnterYourSex -> EnterYourGender
      
      Closes enhancement request #291 by Ragnarok
      1ca401eb
    • Rob Swindell's avatar
      Call smb_updatethread() from sbbs_t::email() to perform Keyop "magic" · 7d52f7e4
      Rob Swindell authored
      As discovered by Keyop and reported via IRC, when replying *to* a local mail box and *not* using the hard-coded email menu (e.g. when when using msglist.js), the original message's "Replied" attribute flag was not set. When replying to a netmail address (at least, Internet or FidoNet, unsure about QWKnetmail), the attribute would be set.
      
      This discrepancy was because this email() function doesn't use the  "modern" smb_addmsg() function (which also calls smb_updatethread()), but add the message body text the old/manual way and never called smb_updatethread(). smb_updatethread() does the thread linkage stuff (which is usually unnoticed in the mail base) *and* sets the "Replied" attribute of the original message, if it's not already set.
      
      This function should be overhauled to use smb_addmsg(), but this 2-line change at least addresses this issue for now. There's probably other places (e.g. importing mail replies via QWK/REP packets) where this thread-linkage and "Replied" attribute flag setting is still not happening.
      7d52f7e4
  15. Sep 23, 2021
    • Rob Swindell's avatar
      When importing FidoNet message area tags > 40 chars, use newsgroup name · 5fc2fc50
      Rob Swindell authored
      Follow-up to previous commit for Keyop (extending max area tag length from 35 to 40/50 chars), when importing echolists/areas.bbs files, if the area tag is longer than 40 chars, then import it into the newsgroup name field instead (63 chars max).
      5fc2fc50
    • Rob Swindell's avatar
      Increase FidoNet echo/area tag max length from 35 to 40/50 chars · 85a2de04
      Rob Swindell authored
      Per FMail.txt:
      Area name
                This is the name of the conference. It can be up to 50
                characters long. This name is often referred to as the
                area tag.
      
      I did not locate a FidoNet spec to contradict that and support a 35 character maximum area tag length. I think Mystic also has a 50 character area tag limit. So 50 character area tags are fine I guess.
      
      So up to 50 characters are now supported in SBBSecho and SCFG for area tags (for message and file echoes). The exception is the (new to 3.19) optional area tag stored in msgs.cnf/file.cnf is limited to 40 characters due to reserved space limitations. If you need a tag stored per sub (most sysops do not) and it needs to be longer than 40 chars, use the newsgroup name instead (limited to 63 chars).
      
      Changed at the request of Keyop via IRC.
      85a2de04
  16. Sep 21, 2021
  17. Sep 19, 2021
  18. Sep 18, 2021
    • Rob Swindell's avatar
      Fix segfault reported with ftpalias.cfg support in some cases · a40109cc
      Rob Swindell authored
      ftpalias() can return true even when the directory is not set to a valid
      directory index (i.e. set to -1), so using as an array index would definitely
      segfault. Part of commit 8ad30b6c by Deuce 3 years ago.
      
      I didn't test this as I'm not sure exactly the combination of ftpalias.cfg
      content and FTP command received that would trigger this, but it's most
      definitely a bug.
      
      So should fix the segfault reported in issue #288.
      a40109cc
  19. Sep 06, 2021
    • Rob Swindell's avatar
      When searching for text in file descriptions, always search ext desc · b10e86f1
      Rob Swindell authored
      Since users can (and usually do) display extended descriptions in their normal file listings anyway, it makes sense to go ahead and search them for the text (e.g. with the 'F' command from the default command shell File menu/prompt). So the "search/display extended info" prompt has been changed to just "Display extended file info" since it no longer controls whether or not the extended description is searched for the text (it always is). The FL_EXFIND was renamed to FL_EXT and only controls whether the extended info is display (the FL_FIND mode flag, always renamed, must also be specified for a find with extended info).
      
      This closes feature request #285 by Phil (@plt).
      b10e86f1
  20. Aug 18, 2021
    • Rob Swindell's avatar
      When writing/reading quotes.txt, ignore first 2 lines if WWIV-type · 51c069a0
      Rob Swindell authored
      WWIV writes 2 lines of metadata to the beginning of its quotes.txt file created for external message editors. Its not clear yet what these lines should contain, but the first line apparently should contain a '#' character since BREdit checks for this character before deciding to throw-away/ignore these lines (don't use them for quoted text). Thanks mlong for this tip!
      
      So if the external editor is set to "WWIV CHAIN.TXT" in SCFG (even if the door doesn't need/use it), then the quotes.txt file created by Synchronet will contain the extra 2 lines. We're just writing a # to the first line and the second line is blank.
      
      This fixes reported issue #188.
      51c069a0
Loading