Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteffen Pingel2013-04-02 10:53:55 +0000
committerGerrit Code Review @ Eclipse.org2013-04-04 22:09:15 +0000
commit13588971667d0529469d4d5c448291029280d6c5 (patch)
tree160a67c41fdf3acf4ed9121e8dfb672a23944e87 /org.eclipse.mylyn.tasks.core
parent5ffbeddd762a2aebc1f02e74bdbecd02bdf29bdb (diff)
downloadorg.eclipse.mylyn.tasks-13588971667d0529469d4d5c448291029280d6c5.tar.gz
org.eclipse.mylyn.tasks-13588971667d0529469d4d5c448291029280d6c5.tar.xz
org.eclipse.mylyn.tasks-13588971667d0529469d4d5c448291029280d6c5.zip
404711: TaskAttachmentPartSource swallows source exception
Change-Id: I285cfdd5f0bfb569524001c3af3838fe5a2ef5e0 Task-Url: https://bugs.eclipse.org/bugs/show_bug.cgi?id=404711
Diffstat (limited to 'org.eclipse.mylyn.tasks.core')
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/data/TaskAttachmentPartSource.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/data/TaskAttachmentPartSource.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/data/TaskAttachmentPartSource.java
index 97287f635..71bf0e744 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/data/TaskAttachmentPartSource.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/data/TaskAttachmentPartSource.java
@@ -16,10 +16,6 @@ import java.io.InputStream;
import org.apache.commons.httpclient.methods.multipart.PartSource;
import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.mylyn.commons.core.StatusHandler;
-import org.eclipse.mylyn.internal.tasks.core.ITasksCoreConstants;
/**
* @since 3.1
@@ -40,8 +36,9 @@ public class TaskAttachmentPartSource implements PartSource {
try {
return attachment.createInputStream(null);
} catch (CoreException e) {
- StatusHandler.log(new Status(IStatus.ERROR, ITasksCoreConstants.ID_PLUGIN, "Error attaching file", e)); //$NON-NLS-1$
- throw new IOException("Failed to create source stream"); //$NON-NLS-1$
+ IOException exception = new IOException("Failed to create source stream"); //$NON-NLS-1$
+ exception.initCause(e);
+ throw exception;
}
}

Back to the top