[PATCH] EasyHack Bug 46610
Daniel Bankston [danthedev]
daniel.dev.libreoffice at gmail.com
Mon Apr 2 19:55:37 PDT 2012
Hello, everyone,
I have attached my patches for EasyHack Bug 46610.
Here is a little more information on what I did and found out:
For both versions of the Region class's Union, Intersect, Exclude, and
XOr, I changed the return types from sal_Bool to void. Then I searched
vcl for all callers of Union, Intersect, Exclude, or XOr. I then
ensured that the return type change would not affect these callers.
Being void, the return type should not be used.
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.
I found no other callers using the return values of these Region methods.
I then successfully built vcl and ran soffice.
Respectfully,
Daniel Bankston
More information about the LibreOffice
mailing list