fix a setjmp() loop in pngread

see

https://github.com/jcupitt/libvips/issues/175

stupid setjmp()
This commit is contained in:
John Cupitt 2014-09-10 09:05:13 +01:00
parent 158237254d
commit 8875e23128
1 changed files with 5 additions and 0 deletions

View File

@ -509,6 +509,11 @@ png2vips_generate( VipsRegion *or,
read->y_pos += 1;
}
/* Turn errors back on. png_read_end() can trigger them too.
*/
if( setjmp( png_jmpbuf( read->pPng ) ) )
return( -1 );
/* We need to shut down the reader immediately at the end of read or
* we won't detach ready for the next image.
*/