[PATCH] EasyHack Bug 46610

Lubos Lunak l.lunak at suse.cz
Tue Apr 3 04:57:25 PDT 2012


On Tuesday 03 of April 2012, Daniel Bankston [danthedev] wrote:
> Hello, everyone,
>
> I have attached my patches for EasyHack Bug 46610.

 Looks good to me, I only removed the return's at the end of function, as they 
are superfluous in void functions. Pushed, thank you.

> I identified that the return value of Intersect was being used in
> vcl/source/edit.cxx::673 in a conditional.  I re-factored the code so
> that the conditional did not use the return value but still called
> Intersect so as to not affect the original functionality.  However, I
> wonder if the original author misunderstood what this Intersect method
> actually does.  Maybe being mislead by the return type, the author's
> intent was to check if these Regions intersected instead of combining
> the regions (which is what I believe these methods actually do)?  This
> usage should probably be checked by someone more knowledgeable and
> experienced than me.  Maybe it is nothing, but it is probably worth
> checking to be sure.

 It seems to me you are correct. I've added !IsEmpty() check to the if(), 
which should do what the original author wanted.

-- 
 Lubos Lunak
 l.lunak at suse.cz


More information about the LibreOffice mailing list