Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/BugzillaRepository.java25
1 files changed, 14 insertions, 11 deletions
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/BugzillaRepository.java b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/BugzillaRepository.java
index bf34876a3..72c8662dc 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/BugzillaRepository.java
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/BugzillaRepository.java
@@ -141,7 +141,7 @@ public class BugzillaRepository
// get the actual bug fron the server and return it
BugReport bug = BugParser.parseBug(in, id, BugzillaPlugin.getDefault().getServerName(), BugzillaPlugin.getDefault().isServerCompatability218(), BugzillaPreferencePage.getUserName(), BugzillaPreferencePage.getPassword());
- return bug;
+ return bug;
}
}
// TODO handle the error
@@ -159,16 +159,19 @@ public class BugzillaRepository
}
catch(Exception e) {
// throw an exception if there is a problem reading the bug from the server
- e.printStackTrace();
- throw new IOException(e.getMessage());
- }
- finally
- {
- try{
- if(in != null)
- in.close();
- }catch(IOException e)
- {
+// e.printStackTrace();
+// throw new IOException(e.getMessage());
+ BugzillaPlugin.log(new Status(
+ IStatus.ERROR,
+ IBugzillaConstants.PLUGIN_ID,
+ IStatus.ERROR,
+ "Problem getting report",
+ e));
+ return null;
+ } finally {
+ try {
+ if(in != null) in.close();
+ } catch(IOException e) {
BugzillaPlugin.log(new Status(IStatus.ERROR, IBugzillaConstants.PLUGIN_ID,IStatus.ERROR,"Problem closing the stream", e));
}
}

Back to the top