lib60870 icon indicating copy to clipboard operation
lib60870 copied to clipboard

- Linux socket: Fix uninitialized variable use in Socket_connect() (#57)

Open S-trace opened this issue 5 years ago • 0 comments

getsockopt() may return -1, set ERRNO = EINPROGRESS (115: Operation now in progress) and not initialze so_error on Kubuntu 19.10 AMD64 with kernel 5.3.0-23-generic

So, initialize the value to -1, and add check for getsockopt() result (and add log message if DEBUG_SOCKET is set).

Fixes https://github.com/mz-automation/lib60870/issues/57

S-trace avatar Nov 18 '19 12:11 S-trace