https://gitlab.synchro.net/main/sbbs/-/commit/bfa0668e5fc4da86b0dea36c
Modified Files:
src/sbbs3/js_socket.c js_socket.h
Log Message:
Report getaddrinfo() failure result in Socket.error and error_str (not errno)
As Nelgin pointed out, a Socket.connect() failure for reasons of address/host lookup failure would report a stale/nonsense Socket.error/error_str value.
This change required us to query/store the socket API/getaddrinfo error string at the time of failure (for the Socket.error_str property value) rather than converting from number to string at the time the property is read.
This does mean that sometimes Socket.error is a errno value and sometimes its
a getaddrinfo (EAI_*) error value. Since the EAI_* values are negative, it should be obvious which is which.
---
þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net