From a7fee637af3ca90077bece90af9887a43f246669 Mon Sep 17 00:00:00 2001 From: "kurtis.heimerl" Date: Fri, 23 Nov 2012 08:36:18 +0000 Subject: r4425 in private: Double check the FD set to be sure that the correct FD was really touched. git-svn-id: http://wush.net/svn/range/software/public/openbts/trunk@4513 19bc5d8c-e614-43d4-8b26-e1612bc8e597 --- CommonLibs/Sockets.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'CommonLibs/Sockets.cpp') diff --git a/CommonLibs/Sockets.cpp b/CommonLibs/Sockets.cpp index b343b7e..62841ad 100644 --- a/CommonLibs/Sockets.cpp +++ b/CommonLibs/Sockets.cpp @@ -190,7 +190,8 @@ int DatagramSocket::read(char* buffer, unsigned timeout) throw SocketError(); } if (sel==0) return -1; - return read(buffer); + if (FD_ISSET(mSocketFD,&fds)) return read(buffer); + return -1; } -- cgit v1.2.3