• src/xpdev/sockwrap.c

    From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Sunday, December 01, 2024 20:17:35
    https://gitlab.synchro.net/main/sbbs/-/commit/1ad5e791f021bedaf6884b42
    Modified Files:
    src/xpdev/sockwrap.c
    Log Message:
    Fix typo in get_socket_errno() definition

    ---
    þ 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:25:53
    https://gitlab.synchro.net/main/sbbs/-/commit/dc6a8901e1b62a031afb399a
    Modified Files:
    src/xpdev/sockwrap.c
    Log Message:
    Some more Coverity paranoia.

    This ones does require SSIZE_MAX... so let's see what the pipes say...

    ---
    þ 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:31:21
    https://gitlab.synchro.net/main/sbbs/-/commit/8b8e70ac870bb4dd29dc7e85
    Modified Files:
    src/xpdev/sockwrap.c
    Log Message:
    Actually we only need to not pass rd, SSIZE_MAX doesn't matter

    ---
    þ 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 01:38:06
    https://gitlab.synchro.net/main/sbbs/-/commit/2f78d96038cd3ce3581b75da
    Modified Files:
    src/xpdev/sockwrap.c
    Log Message:
    Bring some sanity to sendfilesocket()

    Not that there's any need to, it appears that it was written for
    the web server, then discarded for that purpose and now is only
    called from the JS Socket.sendfile() method, which always passes
    NULL and 0 for the last two parameters, and has a copy/pasted
    implementation for TLS sockets. The only consumer of that in
    the tree appears to be gopher_service.js.

    It was apparently to use as a wrapper for the high-performance
    FreeBSD sendfile(), but that code behaved differently than all
    the other platforms, and was disabled (behind USE_SENDFILE, which
    isn't defined anywhere).

    This should really just be folded into either js_socket_sendfilesocket()
    or js_sendfile() with the extra knobs broken off and all the TODO
    comments I'm adding here addressed.

    Though, since Socket.sendfile() returns a bool where true indicates
    that either the size of the file at the start of the function
    was sent, or an EOF was reached, and false indicates that
    "something else happened", some of the TODO comments don't really
    need to be addressed.

    Basically, this is a crap function and it's only used by an even
    more crap JS wrapper, it should be tucked into a backward
    compatibility function, removed from the JSDocs, and forgotten
    about.

    If Coverity keeps complaining about this, I'll wait until after
    the next release and drag this out back and shoot it. Otherwise,
    I'll just forget it ever existed.

    ---
    þ 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 08:59:56
    https://gitlab.synchro.net/main/sbbs/-/commit/8c4af199650226fd7a11fd74
    Modified Files:
    src/xpdev/sockwrap.c
    Log Message:
    *Sigh* Borland.

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