[PATCH] randr: Fix logic in RRPointerToNearestCrtc

walter harms wharms at bfs.de
Thu Jul 31 00:20:22 PDT 2014

Am 30.07.2014 23:38, schrieb Keith Packard:
> walter harms <wharms at bfs.de> writes:
>> distance is normally defined with sqrt(dx*dx+dy*dy)
>> perhaps you can use dx*dx instead of abs() to avoid
>> confusion about dist ?
> That introduces all kinds of range adventures; not sure it's worth the
> trouble?

for now there is no check for any integer overflow either, so i assume that
the values are sane.
Having a common pattern make it more easy to spot trouble for human beings.
NTL the maintainer has to decide. I can only comment.


More information about the xorg-devel mailing list