mirror of
https://github.com/Relintai/MemR.git
synced 2024-11-12 10:25:05 +01:00
Stop parsing when input is GIF87a.
This commit is contained in:
parent
876e5f9e2f
commit
38ac3c7b7d
@ -17,6 +17,15 @@ func read(source_file):
|
||||
file.close()
|
||||
var pos = 0
|
||||
# Header 'GIF89a'
|
||||
|
||||
var sttr : String = ""
|
||||
for i in range(6):
|
||||
sttr += char(data[i])
|
||||
|
||||
if (sttr != "GIF89a"):
|
||||
print("Can only open GIF89a!")
|
||||
return null
|
||||
|
||||
pos = pos + 6
|
||||
# Logical Screen Descriptor
|
||||
var width = get_int(data, pos)
|
||||
|
Loading…
Reference in New Issue
Block a user