Skip to content

Commit

Permalink
a2s_info: replace to_bytes with _pack
Browse files Browse the repository at this point in the history
  • Loading branch information
rossengeorgiev committed Jun 22, 2021
1 parent 2c608af commit 955b38f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion steam/game_servers.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ def a2s_info(server_addr, timeout=2, force_goldsrc=False, challenge=0):
# request server info
payload = _pack('<lc', -1, b'T') + b'Source Engine Query\x00'
if challenge not in (-1, 0): # If a valid challenge was supplied, append it to the payload
payload += challenge.to_bytes(4, 'little', signed = True)
payload += _pack('<i', challenge)

ss.send(payload)
start = _time()
Expand Down

0 comments on commit 955b38f

Please sign in to comment.