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
commitd4fcd505c6321d14991e7a9da44f29fbdd4ce881 (patch)
tree834a857bcbd0158ba3d18ce9593482b961dcd0d7
parent3b2f1dd8b1d873dcca2dcb433edfb925ded366e3 (diff)
parentd0b6725a60a3ca5fa8ca7d2e55a51f9ba8720f85 (diff)
CWS changehid: resync to m90
Notes
split repo tag: ure_ooo/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 6a9ab16845dc..5bcdf8c2497a 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 680c6a241572..b57bc6c3e3b6 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 f196b4f00d60..731d762e23cb 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 01a620e8a238..e6a42793b15d 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 fb0f9409dded..fbddc8f10d97 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 b671e0a62ece..256f094742f5 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 6d79b8d72060..7130d172809b 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