osiSockTest: use strerror rather than strerror_r

Windows vsc19 and mingw on ubuntu were failing with this symbol.
This commit is contained in:
Brendan Chandler
2021-02-22 17:00:31 -06:00
parent 633055aa56
commit f5eb5033f2

View File

@@ -325,9 +325,7 @@ void udpSockFanoutTestIface(const osiSockAddr* addr)
/* test to see if send is possible (not EPERM) */
ret = sendto(sender, buf.bytes, sizeof(buf.bytes), 0, &addr->sa, sizeof(*addr));
if(ret!=(int)sizeof(buf.bytes)) {
char err[256] = {0};
strerror_r(errno, &err, sizeof(err));
testDiag("test sendto() error %d (%d): %s", ret, (int)SOCKERRNO, err);
testDiag("test sendto() error %d (%d): %s", ret, (int)SOCKERRNO, strerror(err));
goto cleanup;
}