mirror of
https://github.com/barronwaffles/dwc_network_server_emulator.git
synced 2026-09-07 18:56:01 -05:00
Fix some small issues
This commit is contained in:
@@ -285,7 +285,7 @@ class Gamestats(LineReceiver):
|
||||
|
||||
profile_data = None
|
||||
|
||||
if 'data' in profile:
|
||||
if profile != None and 'data' in profile:
|
||||
profile_data = gs_query.parse_gamespy_message("\\prof\\" + profile['data'] + "\\final\\")
|
||||
|
||||
if profile_data != None:
|
||||
|
||||
@@ -152,11 +152,11 @@ class GameSpyNatNegServer(object):
|
||||
logger.log(logging.DEBUG, "Received connected command from %s:%s..." % (addr[0], addr[1]))
|
||||
|
||||
if gameid not in self.session_list:
|
||||
pass
|
||||
continue
|
||||
if session_id not in self.session_list[gameid]:
|
||||
pass
|
||||
continue
|
||||
if client_id not in self.session_list[gameid][session_id]:
|
||||
pass
|
||||
continue
|
||||
|
||||
self.session_list[gameid][session_id][client_id]['connected'] = True
|
||||
|
||||
|
||||
@@ -252,7 +252,7 @@ class GameSpyQRServer(object):
|
||||
|
||||
self.sessions[session_id].sent_challenge = True
|
||||
|
||||
if k['publicip'] == "0": #and k['dwc_hoststate'] == "2": # When dwc_hoststate == 2 then it doesn't send an IP, so calculate it ourselves
|
||||
if 'publicip' in k and k['publicip'] == "0": #and k['dwc_hoststate'] == "2": # When dwc_hoststate == 2 then it doesn't send an IP, so calculate it ourselves
|
||||
if self.sessions[session_id].console != 0:
|
||||
k['publicip'] = str(ctypes.c_int32(utils.get_int_be(bytearray([int(x) for x in address[0].split('.')]), 0)).value) # Wii
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user