shithub: choc

Download patch

ref: 81b5839ab1ee28a5acd1e903ae83064bd5c80283
parent: 7d238f61488d550b5bfbe5075b923723bb5d0cfb
author: Simon Howard <fraggle@gmail.com>
date: Sat Apr 19 11:04:13 EDT 2014

server: Fix sending of WAD/DEH checksums to clients.

Clients receive the WAD and dehacked checksums of the controlling
player and are supposed to display a warning at the startup screen if
they do not match. However, reversed logic in the code that sends the
waiting data to clients meant that they were always sent their own
checksums, so the error message was never displayed.

This fixes #384.

--- a/src/net_server.c
+++ b/src/net_server.c
@@ -412,7 +412,7 @@
     // If no controller found (?), send the details that the client
     // is expecting anyway.
 
-    if (controller != NULL)
+    if (controller == NULL)
     {
         controller = client;
     }