瀏覽代碼

Merge pull request #29793 from Faless/enet/bind

Fix ENet incorrectly binding to wildcard.
Rémi Verschelde 6 年之前
父節點
當前提交
63b8c00d55
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      modules/enet/networked_multiplayer_enet.cpp

+ 1 - 0
modules/enet/networked_multiplayer_enet.cpp

@@ -80,6 +80,7 @@ Error NetworkedMultiplayerENet::create_server(int p_port, int p_max_clients, int
 	ERR_FAIL_COND_V(p_out_bandwidth < 0, ERR_INVALID_PARAMETER);
 
 	ENetAddress address;
+	memset(&address, 0, sizeof(address));
 
 #ifdef GODOT_ENET
 	if (bind_ip.is_wildcard()) {