]> git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
a slightly more robust error return check
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 25 Jan 2010 19:49:08 +0000 (19:49 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 25 Jan 2010 19:49:08 +0000 (19:49 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@9855 d7cf8633-e32d-0410-b094-e92efae38249

lhnet.c

diff --git a/lhnet.c b/lhnet.c
index 3ee6267d729802dc65bbd973adf7445ae89a52ed..cd60917f611d3293389b90d4b78e0ae237d4b2a0 100644 (file)
--- a/lhnet.c
+++ b/lhnet.c
@@ -1088,7 +1088,7 @@ int LHNET_Read(lhnetsocket_t *lhnetsocket, void *content, int maxcontentlength,
                        address->port = ntohs(address->addr.in.sin_port);
                        return value;
                }
-               else if (value == -1)
+               else if (value < 0)
                {
                        int e = SOCKETERRNO;
                        if (e == EWOULDBLOCK)