• src/sbbs3/writemsg.cpp

    From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Thu Dec 21 12:38:45 2023
    https://gitlab.synchro.net/main/sbbs/-/commit/daf8fa55aa08b39bf8b4fc6e
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    Fix internal line editor buffer overflow (heap corruption)

    ... wasn't accounting for length of the 'top' buffer (when supplied).

    Also, for raw input mode:
    - flush the input buffer (stray LF) before accepting input
    - turn off raw input mode if run out of bytes (max lines/length reached)

    I was investigating the reported error by Nelgin:
    !ERROR in writemsg.cpp line 1214 (msgeditor) checking
    "max lines (20) exceeded" access=46
    which I was unable to reproduce, when I encountered the issues addressed
    in this commit.

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Tue Dec 26 16:04:06 2023
    https://gitlab.synchro.net/main/sbbs/-/commit/3057bcc20148e3d93d1052a5
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    Insure uploaded text ends in a new-line

    We were appending .sig files to uploaded text, which may not have ended
    in an LF or CRLF sequence. This fixes that.

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Fri Dec 29 17:10:28 2023
    https://gitlab.synchro.net/main/sbbs/-/commit/ee5e3e8ee949f73113909680
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    Fix an error path FILE* leak (CID 462238)

    Go ahead and fix false-positive CID 33482 by adding a NULL check to quotestr()

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Tue Jan 23 18:37:49 2024
    https://gitlab.synchro.net/main/sbbs/-/commit/1321d7f537df2b0eb0c99f33
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    When editing a message, pass the proper to/from/subj/area to drop file

    Fixes issue #704 - not just for JS bbs.edit_msg(), but for all uses of the underlying sbbs_t::editmsg() function.

    Replaced one specific comparison of subnum == INVALID_SUB with call to is_valid_subnum() just to be consistent. No functional change there.

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Tue Feb 13 20:37:50 2024
    https://gitlab.synchro.net/main/sbbs/-/commit/00afb97cc670fdf3e11aa839
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    Improvements to UTF-8 capable external editor support

    1. Add an 8th line to MSGINF (for SlyEdit): the character set expected
    (either "CP437", the default, or "UTF-8") based on the SCFG configuration
    2. Don't apply "Soft-CR" (0x8D) stripping/expansion for UTF-8 editors

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Thu Feb 15 19:24:53 2024
    https://gitlab.synchro.net/main/sbbs/-/commit/0dc20c1f9bf66ae376b0f22d
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    If the quotes.txt file doesn't exist with the right case, try any case

    (but prefer the proper/configured case, based on config in SCFG).

    Works around a problem where DDMsgReader always creates QUOTES.TXT (never quotes.txt), but SBBS tries to read in the file with the case it expects.
    This wouldn't be a problem on case-insensitive file systems (Windows).

    Resolves the writemsg.cpp error reported by Nelgin

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Windows 11)@VERT to Git commit to main/sbbs/master on Thu Feb 15 21:37:00 2024
    https://gitlab.synchro.net/main/sbbs/-/commit/f894f62108ad3251bfcba84c
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    Fix bug in previous commit to this file

    I'm surprised this didn't create a warning somewhere: treating char* as a
    bool!

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Tue Feb 20 23:57:53 2024
    https://gitlab.synchro.net/main/sbbs/-/commit/f754ad9057b0cd076bcf57b1
    Modified Files:
    src/sbbs3/writemsg.cpp
    Log Message:
    Allow UTF-8 sequences in message subjects (passing K_UTF8 to getstr)

    This was the behavior for all string input in SBBS until recently
    (Commit 55ccda6294f82506), with this change, an exception is being
    made for message subjects, but the vast majority of other string
    input is still limited to single-byte (i.e. US-ASCII or CP437)
    characters.

    This should fix issue #720

    ---
    ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net