Re: [Patch] xformsImage::clip() bug fix

2002-10-31 Thread Angus Leeming
On Thursday 31 October 2002 6:02 am, Rob Lahaye wrote: > Hi, > > The attached patch fixes an image clipping bug in > xformsImage.C. The patch fixes the following type of error: > > int i = 5; > unsigned int ui = 20; > int offset = std::max(0U, i - ui); > > Here, (i - ui) is converted to

[Patch] xformsImage::clip() bug fix

2002-10-30 Thread Rob Lahaye
Hi, The attached patch fixes an image clipping bug in xformsImage.C. The patch fixes the following type of error: int i = 5; unsigned int ui = 20; int offset = std::max(0U, i - ui); Here, (i - ui) is converted to unsigned int. If (i - ui) is negative, then this is converted to a very l