[Libreoffice-commits] core.git: 2 commits - external/breakpad scaddins/source
Stephan Bergmann
sbergman at redhat.com
Wed Jan 25 15:16:25 UTC 2017
external/breakpad/ExternalProject_breakpad.mk | 2 +-
scaddins/source/analysis/analysishelper.cxx | 16 ++++++++++------
2 files changed, 11 insertions(+), 7 deletions(-)
New commits:
commit d97bdf10d2654851d69a726b659d68eba3d9076e
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Wed Jan 25 16:11:14 2017 +0100
Avoid calling log10(0)
...to avoid UBSan reporting during CppunitTest_sc_addin_functions_test:
[...]
> Testing file:///data/sbergman/lo-san/core/sc/qa/unit/data/functions/addin/fods/imabs.fods:
> warn:xmloff.style:14186:1:xmloff/source/style/xmlstyle.cxx:300: Here is a duplicate Style
> scaddins/source/analysis/analysishelper.cxx:949:37: runtime error: value -inf is outside the range of representable values of type 'int'
> #0 0x7f77717d11d6 in sca::analysis::ParseDouble(char16_t const*&, double&) scaddins/source/analysis/analysishelper.cxx:949:37
> #1 0x7f77717e39e5 in sca::analysis::Complex::ParseString(rtl::OUString const&, sca::analysis::Complex&) scaddins/source/analysis/analysishelper.cxx:1690:10
> #2 0x7f77717e317f in sca::analysis::Complex::Complex(rtl::OUString const&) scaddins/source/analysis/analysishelper.cxx:1664:10
> #3 0x7f777167fa79 in AnalysisAddIn::getImabs(rtl::OUString const&) scaddins/source/analysis/analysis.cxx:912:19
> #4 0x7f78148bd16a in gcc3::callVirtualMethod(void*, unsigned int, void*, _typelib_TypeDescriptionReference*, bool, unsigned long*, unsigned int, unsigned long*, double*) bridges/source/cpp_uno/gcc3_linux_x86-64/callvirtualmethod.cxx:77:5
> #5 0x7f78148b6b70 in cpp_call(bridges::cpp_uno::shared::UnoInterfaceProxy*, bridges::cpp_uno::shared::VtableSlot, _typelib_TypeDescriptionReference*, int, _typelib_MethodParameter*, void*, void**, _uno_Any**) bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx:233:13
> #6 0x7f78148b3894 in bridges::cpp_uno::shared::unoInterfaceProxyDispatch(_uno_Interface*, _typelib_TypeDescription const*, void*, void**, _uno_Any**) bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx:420:13
> #7 0x7f7772bdd096 in stoc_corefl::IdlInterfaceMethodImpl::invoke(com::sun::star::uno::Any const&, com::sun::star::uno::Sequence<com::sun::star::uno::Any>&) stoc/source/corereflection/criface.cxx:697:9
> #8 0x7f7772bdf45a in non-virtual thunk to stoc_corefl::IdlInterfaceMethodImpl::invoke(com::sun::star::uno::Any const&, com::sun::star::uno::Sequence<com::sun::star::uno::Any>&) stoc/source/corereflection/criface.cxx
> #9 0x7f77d3c63f17 in ScUnoAddInCall::ExecuteCallWithArgs(com::sun::star::uno::Sequence<com::sun::star::uno::Any>&) sc/source/core/tool/addincol.cxx:1466:31
> #10 0x7f77d3c631da in ScUnoAddInCall::ExecuteCall() sc/source/core/tool/addincol.cxx:1444:9
> #11 0x7f77d484504f in ScInterpreter::ScExternal() sc/source/core/tool/interpr4.cxx:2999:19
[...]
Change-Id: Ie31d6374bdac3ae11784d925011c5a67802cdf56
diff --git a/scaddins/source/analysis/analysishelper.cxx b/scaddins/source/analysis/analysishelper.cxx
index 5548c31..d542c04 100644
--- a/scaddins/source/analysis/analysishelper.cxx
+++ b/scaddins/source/analysis/analysishelper.cxx
@@ -946,15 +946,19 @@ bool ParseDouble( const sal_Unicode*& rp, double& rRet )
rp = p;
fInt += fFrac;
- sal_Int32 nLog10 = sal_Int32( log10( fInt ) );
- if( bNegExp )
- nExp = -nExp;
+ if (fInt != 0.0) // exact check; log10(0.0) may entail a pole error
+ {
+ sal_Int32 nLog10 = sal_Int32( log10( fInt ) );
- if( nLog10 + nExp > nMaxExp )
- return false;
+ if( bNegExp )
+ nExp = -nExp;
- fInt = ::rtl::math::pow10Exp( fInt, nExp );
+ if( nLog10 + nExp > nMaxExp )
+ return false;
+
+ fInt = ::rtl::math::pow10Exp( fInt, nExp );
+ }
if( bNegNum )
fInt = -fInt;
commit 16bf916eee4148d66a13323aa69c1bb272c3219e
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Wed Jan 25 16:05:23 2017 +0100
Pass gb_VISIBILITY_FLAGS into external/breakpad
...to avoid UBSan (on Linux) reporting a ODR violation between
google_breakpad::MinidumpDescriptor::kMicrodumpOnConsole (workdir/
UnpackedTarball/breakpad/src/client/linux/handler/minidump_descriptor.cc)
defined in both the crashreport and sofficeapp dynamic libs.
Change-Id: I686a6e2041c70f0aa17a774d705dc71d95d20183
diff --git a/external/breakpad/ExternalProject_breakpad.mk b/external/breakpad/ExternalProject_breakpad.mk
index 10fa6ce..f95b4b2 100644
--- a/external/breakpad/ExternalProject_breakpad.mk
+++ b/external/breakpad/ExternalProject_breakpad.mk
@@ -20,7 +20,7 @@ else # !ifeq($(COM),MSC)
$(call gb_ExternalProject_get_state_target,breakpad,build) :
$(call gb_ExternalProject_run,build,\
- CXX_FLAGS="-O2" ./configure \
+ ./configure CXXFLAGS="-O2 $(gb_VISIBILITY_FLAGS)" \
&& $(MAKE) \
)
More information about the Libreoffice-commits
mailing list