src/network/network_udp.cpp
branchnoai
changeset 10455 22c441f5adf9
parent 10249 58810805030e
child 10513 33cb70ff2f5d
--- a/src/network/network_udp.cpp	Mon May 05 12:35:38 2008 +0000
+++ b/src/network/network_udp.cpp	Wed May 07 21:09:51 2008 +0000
@@ -494,6 +494,8 @@
 
 	// Clear item in gamelist
 	item = NetworkGameListAddItem(inet_addr(inet_ntoa(out_addr.sin_addr)), ntohs(out_addr.sin_port));
+	if (item == NULL) return;
+
 	if (StrEmpty(item->info.server_name)) {
 		memset(&item->info, 0, sizeof(item->info));
 		ttd_strlcpy(item->info.server_name, host, lengthof(item->info.server_name));