Skip to content
Snippets Groups Projects
Commit afc9a2af authored by Tobias S. Josefowitz's avatar Tobias S. Josefowitz
Browse files

Image.XWD: Further improve size check

Thanks to Cezary Cerekwicki <ccerekwicki@opera.com> for the report.
parent 5ad63e5d
Branches
Tags
No related merge requests found
......@@ -302,7 +302,7 @@ void img_xwd__decode(INT32 args,int header_only,int skipcmap)
n++;
push_text("image");
if (s->len-(unsigned int)(header.header_size+header.ncolors*12)<0)
if ((size_t)s->len < (header.header_size+header.ncolors*12))
push_empty_string();
else
push_string(make_shared_binary_string(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment