diff options
author | unknown <stewart@mysql.com> | 2005-02-18 07:06:02 +1100 |
---|---|---|
committer | unknown <stewart@mysql.com> | 2005-02-18 07:06:02 +1100 |
commit | 2504a794f217c8960a87cfb27efed1b5287b8a34 (patch) | |
tree | 656bd18f139c2d780d2476e2b1b1f486078b570c /ndb/src/common/util/SocketServer.cpp | |
parent | d4b0127d725d8a7727a0ff2969cf49cf49195503 (diff) | |
download | mariadb-git-2504a794f217c8960a87cfb27efed1b5287b8a34.tar.gz |
Fix Solaris build problem (jonas pointed out strerror_r is not available).
ndb/src/common/util/SocketServer.cpp:
strerror_r is not available on all platforms. Use plain strerror.
Diffstat (limited to 'ndb/src/common/util/SocketServer.cpp')
-rw-r--r-- | ndb/src/common/util/SocketServer.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/ndb/src/common/util/SocketServer.cpp b/ndb/src/common/util/SocketServer.cpp index a9251f8df4c..6019d24d736 100644 --- a/ndb/src/common/util/SocketServer.cpp +++ b/ndb/src/common/util/SocketServer.cpp @@ -123,11 +123,8 @@ SocketServer::setup(SocketServer::Service * service, /* Get the port we bound to */ SOCKET_SIZE_TYPE sock_len = sizeof(servaddr); if(getsockname(sock,(struct sockaddr*)&servaddr,&sock_len)<0) { - char msg[100]; - if(!strerror_r(errno,msg,sizeof(msg))) - strcpy(msg,"Unknown"); ndbout_c("An error occurred while trying to find out what" - " port we bound to. Error: %s",msg); + " port we bound to. Error: %s",strerror(errno)); NDB_CLOSE_SOCKET(sock); DBUG_RETURN(false); } |