diff --git a/source/java/org/alfresco/repo/importer/ImporterBootstrap.java b/source/java/org/alfresco/repo/importer/ImporterBootstrap.java index 60f8e1fcba..9b4e1b6eb3 100644 --- a/source/java/org/alfresco/repo/importer/ImporterBootstrap.java +++ b/source/java/org/alfresco/repo/importer/ImporterBootstrap.java @@ -443,13 +443,12 @@ public class ImporterBootstrap extends AbstractLifecycleBean catch(Throwable e) { // rollback the transaction - try { if (userTransaction != null) {userTransaction.rollback();} } catch (Exception ex) {} - try {authenticationComponent.clearCurrentSecurityContext(); } catch (Exception ex) {} + try { if (userTransaction != null) {userTransaction.rollback();} } catch (Throwable ex) {} throw new AlfrescoRuntimeException("Bootstrap failed", e); } finally { - authenticationComponent.clearCurrentSecurityContext(); + try {authenticationComponent.clearCurrentSecurityContext(); } catch (Throwable ex) {} } }