• src/sbbs3/js_file.c

    From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Friday, September 13, 2024 20:08:11
    https://gitlab.synchro.net/main/sbbs/-/commit/105627890fa49ca6a6198408
    Modified Files:
    src/sbbs3/js_file.c
    Log Message:
    Eliminte weird gcc (12.2) warning in release build (only)

    Increasing size of mode[] element by 2 bytes eliminated these GCC warnings
    that seem like false-positives to me:

    sbbs.h:194:48: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]
    194 | (ret)[JSSTSpos]=(char)JSSTSstrval[JSSTSpos]; \
    | ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
    js_file.c:225:25: note: in expansion of macro `JSSTRING_TO_STRBUF'
    225 | JSSTRING_TO_STRBUF(cx, str, p->mode, sizeof(p->mode), NULL);
    | ^~~~~~~~~~~~~~~~~~
    js_file.c:42:17: note: at offset 5 into destination object `mode' of size 5
    42 | char mode[5];
    | ^~~~

    Similar use of JSSTRING_TO_STRBUF in other files (js_console.cpp, js_archive.c) (with larger target buffers) does not trigger the same warnings.

    ---
    þ 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 Saturday, September 21, 2024 13:08:41
    https://gitlab.synchro.net/main/sbbs/-/commit/6ba59a06b546c1ed0e3b2b8b
    Modified Files:
    src/sbbs3/js_file.c
    Log Message:
    Add missing NULL pointer check to js_iniReadAll()

    iniReadFile() can return NULL upon file read error or malloc error. Let's not crash if that happens.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Tuesday, October 01, 2024 00:11:39
    https://gitlab.synchro.net/main/sbbs/-/commit/5e1087e457db2b41dab45deb
    Modified Files:
    src/sbbs3/js_file.c
    Log Message:
    File.read() encodes base64, it doesn't decode.

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