On 04/05/2016 06:48 AM, Yuriy M. Kaminskiy wrote:
> As reported in https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=639414
> imlib_image_draw_ellipse(4,4,2,1) triggers divide-by-zero and SIGFPE.
> I verified that bug can be reproduced in the current imlib2.
> Attached patch prevents sigfpe, but probably results in incorrect
> drawing.
> Minor security implications: DoS, if an application draws ellipse using
> coordinates from untrusted input.
> 

Hi,

I don't know the code well at all, but maybe setting dx/dy to 1 when
they are 0 would result in slightly more accurate drawing, setting the
result of the division to 0 would also probably be better then returning
mid function, I don't know which is the better of the two solutions,
maybe raster does.

Cheers

Simon

> 
> 
> ------------------------------------------------------------------------------
> 
> 
> 
> _______________________________________________
> enlightenment-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> 

-- 

Simon Lees (Simotek)                            http://simotek.net

Emergency Update Team                           keybase.io/simotek
SUSE Linux                            Adeliade Australia, UTC+9:30
GPG Fingerprint: 5B87 DB9D 88DC F606 E489 CEC5 0922 C246 02F0 014B

Attachment: signature.asc
Description: OpenPGP digital signature

------------------------------------------------------------------------------
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to