You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by hd...@apache.org on 2014/03/27 16:50:58 UTC

svn commit: r1582365 - /openoffice/trunk/main/ucb/source/ucp/webdav/webdavcontent.cxx

Author: hdu
Date: Thu Mar 27 15:50:58 2014
New Revision: 1582365

URL: http://svn.apache.org/r1582365
Log:
#i124421# force the availability of type_info symbols thrown by the ucb module

When exceptions are passed around in uno::Any types to be thrown later it
was observed on OSX64 that the type_info symbols of these exceptions were
not available anywhere. On most platforms the UNO bridge would synthesize
them by emulating how the platform's toolchain would do it. Forcing the
emission of the type_infos by the real toolchain is much better than
second guessing and reverse engineering its operation.

An even better approach would be to have the ucb throw the exceptions itself
instead of wrapping, rewrapping, unwrapping, etc. them. Once this is done
the dummyThrower helper function is no longer needed.

Modified:
    openoffice/trunk/main/ucb/source/ucp/webdav/webdavcontent.cxx

Modified: openoffice/trunk/main/ucb/source/ucp/webdav/webdavcontent.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/ucb/source/ucp/webdav/webdavcontent.cxx?rev=1582365&r1=1582364&r2=1582365&view=diff
==============================================================================
--- openoffice/trunk/main/ucb/source/ucp/webdav/webdavcontent.cxx (original)
+++ openoffice/trunk/main/ucb/source/ucp/webdav/webdavcontent.cxx Thu Mar 27 15:50:58 2014
@@ -3352,6 +3352,23 @@ uno::Any Content::MapDAVException( const
     return aException;
 }
 
+// #i124421# force the availability of type_info symbols for exceptions
+// that used to be passed around in uno::Any variables and thrown later
+void ucb_dummyThrower( int i) {
+    switch( i) {
+        case 10: throw ucb::InteractiveNetworkGeneralException();
+        case 11: throw ucb::InteractiveAugmentedIOException();
+        case 12: throw ucb::InteractiveNetworkGeneralException();
+        case 13: throw ucb::InteractiveNetworkWriteException();
+        case 14: throw ucb::InteractiveNetworkReadException();
+        case 15: throw ucb::InteractiveNetworkConnectException();
+        case 16: throw ucb::InteractiveLockingLockedException();
+        case 17: throw ucb::InteractiveLockingNotLockedException();
+        case 18: throw ucb::InteractiveNetworkGeneralException();
+        case 19: throw ucb::InteractiveLockingLockExpiredException();
+    }
+}
+
 //=========================================================================
 // static
 bool Content::shouldAccessNetworkAfterException( const DAVException & e )