From d9992a2b78834b86586df2fc27fc549944400efe Mon Sep 17 00:00:00 2001 From: Fabio Alessandrelli Date: Sat, 15 Jun 2019 05:55:41 +0200 Subject: [PATCH] Fix ENet incorrectly binding to wildcard. Values were not properly initialized, and wildcard would evaluate to true in most cases. (cherry picked from commit abe2c22966b9ac1abbd2c0386e78922d901ce8ae) --- modules/enet/networked_multiplayer_enet.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/enet/networked_multiplayer_enet.cpp b/modules/enet/networked_multiplayer_enet.cpp index 9342100767..efc54769e0 100644 --- a/modules/enet/networked_multiplayer_enet.cpp +++ b/modules/enet/networked_multiplayer_enet.cpp @@ -59,6 +59,7 @@ Error NetworkedMultiplayerENet::create_server(int p_port, int p_max_clients, int ERR_FAIL_COND_V(active, ERR_ALREADY_IN_USE); ENetAddress address; + memset(&address, 0, sizeof(address)); #ifdef GODOT_ENET if (bind_ip.is_wildcard()) {