oops logic mixup

Kleis pointed out a suprious return in png load minimise.

see https://github.com/libvips/libvips/issues/1370#issuecomment-513706480
This commit is contained in:
John Cupitt 2019-07-23 12:06:35 +01:00
parent 7f3174c3e5
commit 28090d614f
1 changed files with 4 additions and 4 deletions

View File

@ -203,10 +203,10 @@ read_minimise_cb( VipsImage *out, Read *read )
* file.
*/
if( read->pPng ) {
if( setjmp( png_jmpbuf( read->pPng ) ) )
return;
png_read_end( read->pPng, NULL );
/* Catch and ignore error returns from png_read_end().
*/
if( !setjmp( png_jmpbuf( read->pPng ) ) )
png_read_end( read->pPng, NULL );
}
read_destroy( read );