• src/xpdev/ini_file.c

    From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Saturday, September 27, 2025 16:04:54
    https://gitlab.synchro.net/main/sbbs/-/commit/264234a8af6521996a8a672c
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Allow iniRemoveSection[Fast] to remove the root section

    Fixes crash reported by Deuce when trying to iniCutSection(..., ROOT_SECTION):

    0x00000000007e9b08 in section_match (name=0x7fffffff6dd1 "Flickering...", compare=0x0, case_sensitive=true)
    at ini_file.c:95
    0x00000000007e0df0 in find_section_index (list=0x8056bebc0, section=0x0) at ini_file.c:166
    0x00000000007e167d in iniRemoveSectionFast (list=0x8056bebc0, section=0x0) at ini_file.c:452
    0x00000000007e1756 in iniCutSection (list=0x8056bebc0, section=0x0) at ini_file.c:467

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 02:24:34
    https://gitlab.synchro.net/main/sbbs/-/commit/48edf261f03df00cb5520067
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Add support for root sections to iniParse and friends

    Needed by SyncTERM.

    Note, the error handling of iniParseSections() has changed somewhat... Previously, on an allocation failure, it would return whatever it
    had managed to parse so far with no indication of failure.

    Now, it returns NULL.

    Previously, NULL would be returned if there were no sections.

    Now, NULL will not be returned if there's any global comments, and
    will not be returned if there's any key/value pairs in the global
    section.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 02:24:34
    https://gitlab.synchro.net/main/sbbs/-/commit/8bd0e4b7cbc4c72296d9f9fe
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Braces for Microsoft...

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 02:40:10
    https://gitlab.synchro.net/main/sbbs/-/commit/92d03abf99c1595a1b36a317
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Move stuff around and maybe MSVC won't crash anymore?

    It looks like MSVC is just crashing in random places.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 02:46:32
    https://gitlab.synchro.net/main/sbbs/-/commit/09bdfecc36d178b8c577df23
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Bah, obviously using a variable before setting it doesn't work

    Just expand this and do it the verbose, hard-to-understand way
    because Microsoft still doesn't support C99.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 02:51:45
    https://gitlab.synchro.net/main/sbbs/-/commit/aee17105432b3500c4ed1de5
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fine, I'll at least make the code readable...

    It's still not great due to MSVC, but at least it's not gross.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 07:57:27
    https://gitlab.synchro.net/main/sbbs/-/commit/c02ffa3dbf586d1818ab4d04
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fix crash when there is no root section

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 09:34:20
    https://gitlab.synchro.net/main/sbbs/-/commit/5858834edbaf6c9f8bdd308e
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fix comments

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 11:26:05
    https://gitlab.synchro.net/main/sbbs/-/commit/afc6f520a36b00b1129fc495
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Optimize large INI parsing some more

    Have iniParseSections() sort the section list, then use bsearch()
    to find the section.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 11:38:07
    https://gitlab.synchro.net/main/sbbs/-/commit/34403c1aa40735044f4d9a2f
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Revert "Optimize large INI parsing some more"

    This reverts commit afc6f520a36b00b1129fc49571650782e4c4cc98.
    <DigitalMan> Deuce: I don't think sysops are going to be happy about
    all the config items in SCFG be re-ordered/sorted now

    ---
    ï¿­ 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 Monday, September 29, 2025 11:55:34
    https://gitlab.synchro.net/main/sbbs/-/commit/3350056d0505efa6c0647b6c
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Optimize performance: don't call strlen(prefix) needlessly in loops

    Also, if an empty/blank section prefix is passed to these functions, don't bother calling strnicmp() either.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 21:32:12
    https://gitlab.synchro.net/main/sbbs/-/commit/f0c5d89c6bb6e534fd772aec
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Right, MSVC isn't C99, no inline keyword.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 21:41:10
    https://gitlab.synchro.net/main/sbbs/-/commit/0aa0eb9305c38af17d1789f1
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Try placating Borland some more.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 21:42:22
    https://gitlab.synchro.net/main/sbbs/-/commit/7a36c122e3ebe7f90a395e5d
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Moreland.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 21:44:12
    https://gitlab.synchro.net/main/sbbs/-/commit/2abc7cecd82057989ac6b665
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Snoreland

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 21:52:13
    https://gitlab.synchro.net/main/sbbs/-/commit/a3625e0b9fad76ff938f0757
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Maybe __cdecl works here?

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Monday, September 29, 2025 21:55:32
    https://gitlab.synchro.net/main/sbbs/-/commit/45568d13ac9b8b5c47d7bc0e
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Oh, I need to define this myself.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Tuesday, September 30, 2025 10:41:51
    https://gitlab.synchro.net/main/sbbs/-/commit/9848a07a9f84ab3a6550f87e
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fix valid Coverity issues.

    There's still two that are weird and I think is just Coverity
    halucination that I need to dig into a bit harder.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Tuesday, September 30, 2025 10:49:56
    https://gitlab.synchro.net/main/sbbs/-/commit/925310cf3e656e5fc64890bf
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fix the pipes.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Tuesday, September 30, 2025 10:59:03
    https://gitlab.synchro.net/main/sbbs/-/commit/4929df3cfb1cdc661fd3b9bb
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fix Coverity whinging

    Instead of a char we take the address of, make it a single-element
    array of char we pass by value (ie: the address of it).

    Same same, but Coverity should like it better.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Wednesday, October 01, 2025 20:19:50
    https://gitlab.synchro.net/main/sbbs/-/commit/13f7b0440c884dff072c02f7
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fix Coverity fixes.

    Both of them actually worked and prevented the issue, but Coverity
    didn't know that.

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to Git commit to main/sbbs/master on Thursday, October 02, 2025 11:48:37
    https://gitlab.synchro.net/main/sbbs/-/commit/704a50ccdac528ec8389c6d4
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Fix warning

    ---
    ï¿­ 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 Saturday, October 04, 2025 22:19:48
    https://gitlab.synchro.net/main/sbbs/-/commit/2fdb81f848788709c28e88ff
    Modified Files:
    src/xpdev/ini_file.c
    Log Message:
    Make all ini file read function support the same max length, now 2048 bytes

    INI_MAX_LINE_LEN used to be defined as 2048, but that includes the NUL terminator, so effectively 2047 bytes per line were supported in all the
    ini functions *except* iniReadFile(), which supported 2048 chars per line.

    Now all the ini functions should agree: 2048 is the max chars per line
    because INI_MAX_LINE_LEN is now defined as 2049.

    I figured this was a better solution than reducing the line lengths supported by iniReadFile().

    Fix for issue #982

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