From dbd0e845ffe3fc37e6f174d8f5e926aff5af5346 Mon Sep 17 00:00:00 2001 From: John Cupitt Date: Mon, 1 Mar 2010 17:37:20 +0000 Subject: [PATCH] im_lineset() needs to ask for WIO of mask and ink --- ChangeLog | 1 + libvips/inplace/line_draw.c | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/ChangeLog b/ChangeLog index c3b643d4..c11b2e41 100644 --- a/ChangeLog +++ b/ChangeLog @@ -19,6 +19,7 @@ almostdeprecated to avoid breakage - im_csv2vips(): allow lines that end with EOF rather than \n - im_vips2tiff has a bigtiff option +- oops, im_lineset() needs to ask for WIO of mask and ink 15/1/10 started 7.21.1 - added "written" callbacks, used to implement write to non-vips formats diff --git a/libvips/inplace/line_draw.c b/libvips/inplace/line_draw.c index dc744ff9..7a790de6 100644 --- a/libvips/inplace/line_draw.c +++ b/libvips/inplace/line_draw.c @@ -40,6 +40,8 @@ * - im_incheck() changed to im_makerw() * 5/12/06 * - im_invalidate() after paint + * 1/3/10 + * - oops, lineset needs to ask for WIO of mask and ink */ /* @@ -438,6 +440,10 @@ im_lineset( IMAGE *in, IMAGE *out, IMAGE *mask, IMAGE *ink, mask_rect.width = mask->Xsize; mask_rect.height = mask->Ysize; + if( im_incheck( ink ) || + im_incheck( mask ) ) + return( -1 ); + for( i = 0; i < n; i++ ) { if( im_fastlineuser( out, x1v[i], y1v[i], x2v[i], y2v[i], im_plotmask, ink->data, mask->data, &mask_rect ) )