• src/sbbs3/js_filebase.c js_msgbase.c

    From Rob Swindell@VERT to Git commit to main/sbbs/master on Wed Oct 19 14:23:26 2022
    https://gitlab.synchro.net/main/sbbs/-/commit/127c322a464c610959f3311c
    Modified Files:
    src/sbbs3/js_filebase.c js_msgbase.c
    Log Message:
    Fix JSDOC typos

    ---
    ■ 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 Sat Sep 14 14:20:08 2024
    https://gitlab.synchro.net/main/sbbs/-/commit/a398abb2fe57ee51eb2cde29
    Modified Files:
    src/sbbs3/js_filebase.c js_msgbase.c
    Log Message:
    Don't heap allocate argument to MsgBase and FileBase constructors

    Nelgin reported a weird error with a failed very large allocation for the base/code argument to the FileBase constructor. There's no good reason
    these strings were heap-allocated in the first place, so just change to
    use a stack allocated variable instead. I don't know why this would fix anything, but at least there's one less heap allocation and potential
    for memory leak here.

    Fix 2 bugs in js_update_file():
    1. missing parenthesis (really?!? Caught by Coverity - sigh) in last
    commmit caused attempt/failure/error to remove file after making any
    updates. The removing is only supposed to happen when its necessary to
    remove and re-add the file to the filebase (e.g. updating extended
    description or auxdata).
    2. Wrong filename used in 'removing' exception string.

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