Commit 5111498e authored by Simon Budig's avatar Simon Budig

More input validation in the psd load plugin

plug-ins/file-psd/psd-load.c: Avoid dereferencing a random pointer
on chn_a[cidx].data[i] when comp_mode is unrecognized.
Spotted by Mikael Magnusson <mikachu@gmail.com>.
parent 0829e5b0
......@@ -1546,6 +1546,7 @@ add_merged_image (const gint32 image_id,
case PSD_COMP_ZIP: /* ? */
case PSD_COMP_ZIP_PRED:
default:
g_set_error (error, G_FILE_ERROR, G_FILE_ERROR_FAILED,
_("Unsupported compression mode: %d"), comp_mode);
return -1;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment