We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bad58f4 commit 6c3fd1eCopy full SHA for 6c3fd1e
sc2reader/utils.py
@@ -497,7 +497,7 @@ def read_header(file):
497
buffer = ReplayBuffer(file)
498
499
#Sanity check that the input is in fact an MPQ file
500
- if buffer.read_hex(4).upper() != "4D50511B":
+ if buffer.empty or buffer.read_hex(4).upper() != "4D50511B":
501
print "Header Hex was: %s" % buffer.read_hex(4).upper()
502
raise ValueError("File '%s' is not an MPQ file" % file.name)
503
0 commit comments