diff --git a/src/d_net.c b/src/d_net.c index 98fe71ab8..70cdc5f14 100644 --- a/src/d_net.c +++ b/src/d_net.c @@ -716,7 +716,7 @@ void Net_CloseConnection(INT32 node) if (!node) return; - if (node >= MAXNETNODES) // prevent invalid nodes from crashing the game + if (node < 0 || node >= MAXNETNODES) // prevent invalid nodes from crashing the game { CONS_Alert(CONS_WARNING, M_GetText("Net_CloseConnection: invalid node %d detected!\n"), node); return;