• src/smblib/smblib.c

    From Rob Swindell@1:103/705 to Git commit to main/sbbs/master on Wed Dec 9 00:42:43 2020
    https://gitlab.synchro.net/main/sbbs/-/commit/05104f134188b139a6f3e5ba
    Modified Files:
    src/smblib/smblib.c
    Log Message:
    When a message has been forwarded, invalidate the "to" ext/net ptrsThe convenience pointers to_ext and to_net need to be invalidated (nullified) if we are going to allow forwarding from local email boxes to network mail and keep all the original message header fields in tact.The "Forwarded" field must now be added *before* any new recipient information (local user extension or network address of the forwarding destination).This is part of the solution to request #83, #108, and #141.
    --- SBBSecho 3.11-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Rob Swindell@1:103/705 to Git commit to main/sbbs/master on Sun May 2 17:14:43 2021
    https://gitlab.synchro.net/main/sbbs/-/commit/ba1f38cc4126d388c6a897ef
    Modified Files:
    src/smblib/smblib.c
    Log Message:
    When adding a msg/file header, remove the DELETE attributeWhen moving or renewing files, they're first removed and then added and they were being added with the DELETE attribute set. The filenames are displayed in red when staged for deletion/removal, so that's how I noticed. Oops.
    --- SBBSecho 3.14-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Rob Swindell (on Debian Linux)@1:103/705 to Git commit to main/sbbs/master on Thu Nov 19 09:20:50 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/ce3494e738760fd80e4c44f0
    Modified Files:
    src/smblib/smblib.c
    Log Message:
    smblib: free text_subtype/text_charset in smb_freemsghdrmem()

    smb_freemsghdrmem() ended with clear_convenience_ptrs(), which NULLs text_subtype and text_charset along with the pointers into header-field
    data. Those two are not such pointers: smb_parse_content_type() strdup()s
    them from a text/* Content-Type field, so they leaked each time a header
    with one was freed this way. MsgBase.put_msg_header() does that on every
    call (it re-reads the header and frees its fields before re-parsing the
    JS header object), leaking both strings per call; valgrind flagged it in
    the jsexec-testsuite-valgrind CI jobs.

    Free them alongside the header fields they are derived from.
    smb_freemsgmem() calls smb_freemsghdrmem(), so its own frees of the two
    are dropped.

    Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
    --- SBBSecho 3.38-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)