• src/encode/lzh.c

    From deuce@VERT to CVS commit on Tuesday, April 14, 2020 05:30:35
    src/encode lzh.c 1.13 1.14
    Update of /cvsroot/sbbs/src/encode
    In directory cvs:/tmp/cvs-serv19289

    Modified Files:
    lzh.c
    Log Message:
    Fix fencepost error detected by Coverity...

    Because the test to continue is *after* the loop, we can't continue
    when c is the last index into lzh->son, or the code will make use of lzh->son[sizeof(lzh->son)/sizeof(lzh->son[0])] which is outside the bounds
    of the array.




    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From deuce@VERT to CVS commit on Wednesday, April 15, 2020 09:54:55
    src/encode lzh.c 1.14 1.15
    Update of /cvsroot/sbbs/src/encode
    In directory cvs:/tmp/cvs-serv688

    Modified Files:
    lzh.c
    Log Message:
    More weirdness uncovered by Coverity.
    To be fair, this is all weird.




    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From deuce@VERT to CVS commit on Friday, April 17, 2020 06:08:11
    src/encode lzh.c 1.15 1.16
    Update of /cvsroot/sbbs/src/encode
    In directory cvs:/tmp/cvs-serv1738

    Modified Files:
    lzh.c
    Log Message:
    I'm going to get the LZH to pass Coverity if it's the last thing I do!




    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Thursday, January 02, 2025 10:50:20
    https://gitlab.synchro.net/main/sbbs/-/commit/bd91f791e7aad5f2626bb58e
    Modified Files:
    src/encode/lzh.c
    Log Message:
    Attempt to fix Coverity CID 454296

    This is that rare case where a Coverity fix makes the code more
    obvious and shorter.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Friday, January 03, 2025 23:30:36
    https://gitlab.synchro.net/main/sbbs/-/commit/be80773e436f62d5d927ea28
    Modified Files:
    src/encode/lzh.c
    Log Message:
    Add a (much) larger test vector for LZH

    It has a 4k window, we need to fill it multiple times.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Saturday, January 04, 2025 16:19:54
    https://gitlab.synchro.net/main/sbbs/-/commit/bdc64cc9090f0d6825c4dcc5
    Modified Files:
    src/encode/lzh.c
    Log Message:
    Add a (much) larger test vector for LZH

    It has a 4k window, we need to fill it multiple times.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Sunday, January 05, 2025 09:21:55
    https://gitlab.synchro.net/main/sbbs/-/commit/89d74a14f8cf6fdeae6984a0
    Modified Files:
    src/encode/lzh.c
    Log Message:
    More LZH updates

    - Make lzh_update() return a bool indicating success
    - Eliminated calculating array size, use macro
    - Fail if the current entry is not in the frequency array

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Sunday, January 05, 2025 09:37:11
    https://gitlab.synchro.net/main/sbbs/-/commit/8e14b84ef2708e8ccbb4d90d
    Modified Files:
    src/encode/lzh.c
    Log Message:
    What kind of monster puts a size_t after a uint8_t in a struct?

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Sunday, January 05, 2025 21:15:24
    https://gitlab.synchro.net/main/sbbs/-/commit/a57998b2da99464fd99ea375
    Modified Files:
    src/encode/lzh.c
    Log Message:
    Cap the search at LZH_ROOT (avoiding the sentry)

    This should take care of the last three overflow and truncation
    concerns that Coverity has.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Monday, January 06, 2025 06:48:49
    https://gitlab.synchro.net/main/sbbs/-/commit/82efb6413394432221bd6cbb
    Modified Files:
    src/encode/lzh.c
    Log Message:
    Suppress Coverity assertion.

    Coverity believes that after checking that c < LZH_ROOT (636), it's
    possible for (c + 1) to be greater than 65535.

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