Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(367)

Unified Diff: editor/tools/plugins/com.google.dart.tools.debug.core/src/com/google/dart/tools/debug/core/util/ResourceServerHandler.java

Issue 10690002: Fix some issues when debugging against package: libraries (Dartium and command-line). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: editor/tools/plugins/com.google.dart.tools.debug.core/src/com/google/dart/tools/debug/core/util/ResourceServerHandler.java
===================================================================
--- editor/tools/plugins/com.google.dart.tools.debug.core/src/com/google/dart/tools/debug/core/util/ResourceServerHandler.java (revision 9145)
+++ editor/tools/plugins/com.google.dart.tools.debug.core/src/com/google/dart/tools/debug/core/util/ResourceServerHandler.java (working copy)
@@ -45,6 +45,7 @@
import java.net.ConnectException;
import java.net.InetAddress;
import java.net.Socket;
+import java.net.SocketException;
import java.net.URI;
import java.net.URL;
import java.net.URLConnection;
@@ -263,7 +264,7 @@
safeClose(socket);
// ignore java.net.SocketException: Connection reset
- if (!(ioe instanceof ConnectException)) {
+ if (!(ioe instanceof ConnectException) && !isConnectionReset(ioe)) {
DartDebugCorePlugin.logError(ioe);
}
} catch (Throwable t) {
@@ -592,6 +593,16 @@
return false;
}
+ private boolean isConnectionReset(IOException ioe) {
+ // ignore java.net.SocketException: Connection reset
+
+ if (ioe instanceof SocketException) {
+ return "Connection reset".equals(ioe.getMessage());
+ }
+
+ return false;
+ }
+
private boolean isFileJsArtifact(File javaFile) {
return javaFile.getName().endsWith(".dart.js");
}

Powered by Google App Engine
This is Rietveld 408576698