This commit is contained in:
Ryan Oldenburg 2020-11-20 20:13:06 -06:00
parent e3e94cff85
commit f978516b39

View file

@ -21,7 +21,7 @@ proc decodeBmp*(data: string): Image =
raise newException(PixieError, "Unsupported BMP data format")
if compression notin [0, 3]:
raise newException(PixieError, "Invalid BMP data format")
raise newException(PixieError, "Unsupported BMP data format")
let channels = if bits == 32: 4 else: 3
if width * height * channels + offset > data.len: