• docs/v322_new.md src/sbbs3/smbutil.c

    From Rob Swindell (on Debian Linux)@1:103/705 to Git commit to main/sbbs/master on Thursday, November 19, 2026 09:38:57
    https://gitlab.synchro.net/main/sbbs/-/commit/b17526d9ed681dec30a638aa
    Modified Files:
    docs/v322_new.md src/sbbs3/smbutil.c
    Log Message:
    smbutil: test pack's header allocation result before offsetting it

    Pack added the base's header offset to smb_fallochdr()'s return value
    before testing it for an error. With the usual header offset (32) the
    sum stayed negative, so the message was still skipped but the error
    was logged with the wrong code (e.g. -70 for SMB_ERR_HDR_OFFSET,
    -102). A base with a header offset larger than the error code's
    magnitude would have had the failure go unnoticed and the header
    written at a bogus offset. The header offset is now added only to a
    successful allocation.

    Also note the allocation and chksmb fixes in the v3.22 release notes.

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