summaryrefslogtreecommitdiff
path: root/scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-08-15 16:17:25 +0200
committerNoel Grandin <noel@peralex.com>2014-09-25 13:47:25 +0200
commit83636d2c09802aeeb1b30078022d228d04da21eb (patch)
tree8a0c619e16c1f6b5388939d5da2956f7ef758c19 /scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java
parentcf49392511e98851174b353782df9eb6bac46f77 (diff)
java: when rethrowing exceptions, store the original cause
so that we get a nice complete stacktrace when it hits the final handler Change-Id: Iec4fcc15a2a25c55f591b5e069dce3d010197a90
Diffstat (limited to 'scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java')
-rw-r--r--scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java11
1 files changed, 4 insertions, 7 deletions
diff --git a/scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java b/scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java
index d36bada434b0..be9dd42db9f1 100644
--- a/scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java
+++ b/scripting/java/com/sun/star/script/framework/container/UnoPkgContainer.java
@@ -28,12 +28,9 @@ import java.io.OutputStream;
import java.io.InputStream;
import com.sun.star.uno.XComponentContext;
-
import com.sun.star.uno.UnoRuntime;
-
import com.sun.star.io.XOutputStream;
import com.sun.star.io.XTruncate;
-
import com.sun.star.deployment.XPackage;
public class UnoPkgContainer extends ParcelContainer
@@ -226,7 +223,7 @@ public class UnoPkgContainer extends ParcelContainer
{
LogUtils.DEBUG("getUnoPackagesDB() caught Exception: " + e );
LogUtils.DEBUG( LogUtils.getTrace( e ) );
- throw new com.sun.star.lang.WrappedTargetException( e.toString());
+ throw new com.sun.star.lang.WrappedTargetException(e);
}
finally
{
@@ -280,7 +277,7 @@ public class UnoPkgContainer extends ParcelContainer
catch( Exception e )
{
LogUtils.DEBUG("In writeUnoPackageDB() Exception: " + e );
- throw new com.sun.star.lang.WrappedTargetException( e.toString());
+ throw new com.sun.star.lang.WrappedTargetException(e);
}
finally
{
@@ -317,7 +314,7 @@ public class UnoPkgContainer extends ParcelContainer
}
catch (com.sun.star.deployment.ExtensionRemovedException e)
{
- throw new com.sun.star.lang.WrappedTargetException(e.toString(), this, e);
+ throw new com.sun.star.lang.WrappedTargetException(e.getMessage(), this, e);
}
processUnoPackage( uri, language );
@@ -331,7 +328,7 @@ public class UnoPkgContainer extends ParcelContainer
}
catch ( java.io.IOException ioe )
{
- throw new com.sun.star.lang.WrappedTargetException( ioe.toString());
+ throw new com.sun.star.lang.WrappedTargetException(ioe);
}
}
db.addPackage( language, uri );