Use the size argument to ensure checking the header doesn't read past the buffer bounds when reading corrupt/truncated headers from image files.
Use the size argument to ensure checking the header doesn't read past the buffer bounds when reading corrupt/truncated headers from image files.