https://gitlab.synchro.net/main/sbbs/-/commit/4090d823bba9fa4630bd79c2
Modified Files:
src/sbbs3/websrvr.c
Log Message:
Solve the active_clients exceeds configured max_clients issue
e.g. with [Web] max_clients configured for 200, the following could occur: sbbs: web 0522 HTTP [34.45.142.114] Session thread terminated (220 clients, 378 threads remain, 128627 served)
The issue was that the active_client count is incremented in the http_session_thread(), but was being checked in the main web server/listening thread.
So now we'll check in both threads, but allow more HTTPS/TLS client threads
(10 more) than the configured max, to allow for successfull sending of error 503 (up to a point), while HTTP (non-TLS) connections exceeding the configured max will be immediately dropped without creating a session thread.
We now no longer increment the client highwater mark for connections that exceed the maximum.
Also fix send_error() to not log the Connection: close\r\nContent-Length: 0\r\n portion of 503 errors.
--- SBBSecho 3.28-Linux
* Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)