Merge pull request #264 from lovell/magick-destroy-exception-guard

Ensure expected signature in ExceptionInfo before destroy
This commit is contained in:
John Cupitt 2015-04-18 16:40:51 +01:00
commit 0ac29f0b0b

View File

@ -143,7 +143,9 @@ read_free( Read *read )
VIPS_FREEF( DestroyImage, read->image );
VIPS_FREEF( DestroyImageInfo, read->image_info );
VIPS_FREE( read->frames );
DestroyExceptionInfo( &read->exception );
if ( (&read->exception)->signature == MagickSignature ) {
DestroyExceptionInfo( &read->exception );
}
VIPS_FREEF( vips_g_mutex_free, read->lock );
}