summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMathias Bauer <mba@openoffice.org>2010-10-21 15:10:42 +0200
committerMathias Bauer <mba@openoffice.org>2010-10-21 15:10:42 +0200
commitf1dc11f3b0d547a87a4d047f0299086733150f2f (patch)
tree8185b958c16821ef107cf6fa5807d098cce01a17
parent045cb291526592a5b3e786600426bf4f62912b8b (diff)
parent33deb5b2f43e189cb2d98bce2331597250e6b218 (diff)
CWS changehid: resync to m90ooo/DEV300_m91
-rw-r--r--bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx49
-rw-r--r--pyuno/zipcore/python.sh2
-rw-r--r--sal/inc/rtl/malformeduriexception.hxx4
-rw-r--r--sal/qa/OStringBuffer/rtl_OStringBuffer.cxx30
-rw-r--r--sal/qa/OStringBuffer/rtl_String_Const.h6
-rw-r--r--stoc/prj/build.lst2
-rw-r--r--ure/source/startup.sh2
7 files changed, 53 insertions, 42 deletions
diff --git a/bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx b/bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx
index 37fab3d8b..d2c8f3312 100644
--- a/bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx
@@ -28,10 +28,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_bridges.hxx"
+#include <exception>
+#include <typeinfo>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <rtl/alloc.h>
+
+#include "rtl/alloc.h"
+#include "rtl/ustrbuf.hxx"
#include <com/sun/star/uno/genfunc.hxx>
#include "com/sun/star/uno/RuntimeException.hpp"
@@ -237,6 +241,18 @@ static void callVirtualMethod(void * pThis, sal_uInt32 nVtableIndex,
//==================================================================================================
+namespace {
+
+void appendCString(OUStringBuffer & buffer, char const * text) {
+ if (text != 0) {
+ buffer.append(
+ OStringToOUString(OString(text), RTL_TEXTENCODING_ISO_8859_1));
+ // use 8859-1 to avoid conversion failure
+ }
+}
+
+}
+
static void cpp_call(
bridges::cpp_uno::shared::UnoInterfaceProxy * pThis,
bridges::cpp_uno::shared::VtableSlot aVtableSlot,
@@ -369,12 +385,31 @@ static void cpp_call(
try
{
- callVirtualMethod(
- pAdjustedThisPtr, aVtableSlot.index,
- pCppReturn, pReturnTypeRef, bSimpleReturn,
- pStackStart, ( pStack - pStackStart ),
- pGPR, nGPR,
- pFPR, nFPR );
+ try {
+ callVirtualMethod(
+ pAdjustedThisPtr, aVtableSlot.index,
+ pCppReturn, pReturnTypeRef, bSimpleReturn,
+ pStackStart, ( pStack - pStackStart ),
+ pGPR, nGPR,
+ pFPR, nFPR );
+ } catch (Exception &) {
+ throw;
+ } catch (std::exception & e) {
+ OUStringBuffer buf;
+ buf.appendAscii(RTL_CONSTASCII_STRINGPARAM("C++ code threw "));
+ appendCString(buf, typeid(e).name());
+ buf.appendAscii(RTL_CONSTASCII_STRINGPARAM(": "));
+ appendCString(buf, e.what());
+ throw RuntimeException(
+ buf.makeStringAndClear(), Reference< XInterface >());
+ } catch (...) {
+ throw RuntimeException(
+ OUString(
+ RTL_CONSTASCII_USTRINGPARAM(
+ "C++ code threw unknown exception")),
+ Reference< XInterface >());
+ }
+
// NO exception occured...
*ppUnoExc = 0;
diff --git a/pyuno/zipcore/python.sh b/pyuno/zipcore/python.sh
index f471b1dfd..b53e369fe 100644
--- a/pyuno/zipcore/python.sh
+++ b/pyuno/zipcore/python.sh
@@ -44,7 +44,7 @@ PATH=$sd_prog${PATH+:$PATH}
export PATH
# Set LD_LIBRARY_PATH so that "import pyuno" finds libpyuno.so:
-LD_LIBRARY_PATH=$sd_prog/../basis-link/program:$sd_prog/../basis-link/ure-link/lib${LD_LIBRARY_PATH+:$LD_LIBRARY_PATH}
+LD_LIBRARY_PATH=$sd_prog/../basis-link/program:$sd_prog/../basis-link/ure-link/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
export LD_LIBRARY_PATH
# Set UNO_PATH so that "officehelper.bootstrap()" can find soffice executable:
diff --git a/sal/inc/rtl/malformeduriexception.hxx b/sal/inc/rtl/malformeduriexception.hxx
index 4a5bfbe85..5d824c3bf 100644
--- a/sal/inc/rtl/malformeduriexception.hxx
+++ b/sal/inc/rtl/malformeduriexception.hxx
@@ -53,8 +53,8 @@ public:
inline SAL_EXCEPTION_DLLPRIVATE ~MalformedUriException() {}
inline SAL_EXCEPTION_DLLPRIVATE MalformedUriException operator =(
- MalformedUriException const & other)
- { m_aMessage = other.m_aMessage; return *this; }
+ MalformedUriException const & rOther)
+ { m_aMessage = rOther.m_aMessage; return *this; }
/** Get the message.
diff --git a/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx b/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx
index 2b091f440..bdbd41bc2 100644
--- a/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx
+++ b/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx
@@ -14789,11 +14789,7 @@ sal_Bool test_append( const char** resArray, int n, sal_Int16 radix,
{
::rtl::OStringBuffer aStrBuf( *arrOUS[0] );
OString expVal( kTestStr116 );
-#if defined(UNX) || defined(OS2)
- sal_Int64 input = 9223372036854775807LL;
-#else
- sal_Int64 input = 9223372036854775807;
-#endif
+ sal_Int64 input = SAL_CONST_INT64(9223372036854775807);
aStrBuf.append( input );
CPPUNIT_ASSERT_MESSAGE
@@ -14873,11 +14869,7 @@ sal_Bool test_append( const char** resArray, int n, sal_Int16 radix,
{
::rtl::OStringBuffer aStrBuf( *arrOUS[1] );
OString expVal( kTestStr118 );
-#if defined(UNX) || defined(OS2)
- sal_Int64 input = 9223372036854775807LL;
-#else
- sal_Int64 input = 9223372036854775807;
-#endif
+ sal_Int64 input = SAL_CONST_INT64(9223372036854775807);
aStrBuf.append( input );
CPPUNIT_ASSERT_MESSAGE
@@ -14956,11 +14948,7 @@ sal_Bool test_append( const char** resArray, int n, sal_Int16 radix,
{
::rtl::OStringBuffer aStrBuf( *arrOUS[2] );
OString expVal( kTestStr118 );
-#if defined(UNX) || defined(OS2)
- sal_Int64 input = 9223372036854775807LL;
-#else
- sal_Int64 input = 9223372036854775807;
-#endif
+ sal_Int64 input = SAL_CONST_INT64(9223372036854775807);
aStrBuf.append( input );
CPPUNIT_ASSERT_MESSAGE
@@ -15039,11 +15027,7 @@ sal_Bool test_append( const char** resArray, int n, sal_Int16 radix,
{
::rtl::OStringBuffer aStrBuf( *arrOUS[3] );
OString expVal( kTestStr118 );
-#if defined(UNX) || defined(OS2)
- sal_Int64 input = 9223372036854775807LL;
-#else
- sal_Int64 input = 9223372036854775807;
-#endif
+ sal_Int64 input = SAL_CONST_INT64(9223372036854775807);
aStrBuf.append( input );
CPPUNIT_ASSERT_MESSAGE
@@ -15122,11 +15106,7 @@ sal_Bool test_append( const char** resArray, int n, sal_Int16 radix,
{
::rtl::OStringBuffer aStrBuf( *arrOUS[4] );
OString expVal( kTestStr120 );
-#if defined(UNX) || defined(OS2)
- sal_Int64 input = 9223372036854775807LL;
-#else
- sal_Int64 input = 9223372036854775807;
-#endif
+ sal_Int64 input = SAL_CONST_INT64(9223372036854775807);
aStrBuf.append( input );
CPPUNIT_ASSERT_MESSAGE
diff --git a/sal/qa/OStringBuffer/rtl_String_Const.h b/sal/qa/OStringBuffer/rtl_String_Const.h
index dc905ac60..0c058273c 100644
--- a/sal/qa/OStringBuffer/rtl_String_Const.h
+++ b/sal/qa/OStringBuffer/rtl_String_Const.h
@@ -357,11 +357,7 @@ static const sal_Int16 kSInt16Max = SHRT_MAX;
static const sal_Int32 kUInt16Max = USHRT_MAX;
static const sal_Int32 kSInt32Max = INT_MAX;
static const sal_Int64 kUInt32Max = UINT_MAX;
-#if defined(UNX) || defined(OS2)
-static const sal_Int64 kSInt64Max = 9223372036854775807LL;
-#else
-static const sal_Int64 kSInt64Max = 9223372036854775807;
-#endif
+static const sal_Int64 kSInt64Max = SAL_CONST_INT64(9223372036854775807);
//------------------------------------------------------------------------
diff --git a/stoc/prj/build.lst b/stoc/prj/build.lst
index b671e0a62..256f09474 100644
--- a/stoc/prj/build.lst
+++ b/stoc/prj/build.lst
@@ -1,4 +1,4 @@
-tc stoc : rdbmaker cppuhelper cppu jvmaccess sal salhelper jvmfwk xmlreader NULL
+tc stoc : rdbmaker cppuhelper cppu jvmaccess sal salhelper jvmfwk xmlreader LIBXSTL:libxslt NULL
tc stoc usr1 - all tc_mkout NULL
tc stoc\inc nmake - all tc_inc NULL
tc stoc\source\defaultregistry nmake - all tc_defr tc_boot tc_inc NULL
diff --git a/ure/source/startup.sh b/ure/source/startup.sh
index 70748f262..7f973c5bf 100644
--- a/ure/source/startup.sh
+++ b/ure/source/startup.sh
@@ -39,7 +39,7 @@ epath=`dirname "$0"`
if [ -x "${epath}/javaldx" ] ; then
jpath=`"${epath}/javaldx" $my_envargs`
if [ -n "${jpath}" ]; then
- LD_LIBRARY_PATH=${jpath}${LD_LIBRARY_PATH+:${LD_LIBRARY_PATH}}
+ LD_LIBRARY_PATH=${jpath}${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
export LD_LIBRARY_PATH
fi
fi