--- a/src/jdk.jfr/share/classes/jdk/jfr/internal/instrument/SocketInputStreamInstrumentor.java Fri Feb 08 18:16:53 2019 +0000
+++ b/src/jdk.jfr/share/classes/jdk/jfr/internal/instrument/SocketInputStreamInstrumentor.java Sat Feb 09 07:56:19 2019 +0000
@@ -28,7 +28,6 @@
import java.io.IOException;
import java.net.InetAddress;
import java.net.Socket;
-import java.net.SocketException;
import jdk.jfr.events.SocketReadEvent;
@@ -73,17 +72,6 @@
return bytesRead;
}
+ // private field in java.net.Socket$SocketInputStream
private Socket parent;
-
- InetAddress getInetAddress() {
- throw new RuntimeException();
- }
-
- int getPort() {
- throw new RuntimeException();
- }
-
- int getSoTimeout() throws SocketException {
- throw new RuntimeException();
- }
}
--- a/src/jdk.jfr/share/classes/jdk/jfr/internal/instrument/SocketOutputStreamInstrumentor.java Fri Feb 08 18:16:53 2019 +0000
+++ b/src/jdk.jfr/share/classes/jdk/jfr/internal/instrument/SocketOutputStreamInstrumentor.java Sat Feb 09 07:56:19 2019 +0000
@@ -60,7 +60,7 @@
event.host = remote.getHostName();
event.address = remote.getHostAddress();
event.port = parent.getPort();
- event.bytesWritten = bytesWritten < 0 ? 0 : bytesWritten;
+ event.bytesWritten = bytesWritten;
event.commit();
event.reset();
@@ -68,13 +68,6 @@
}
}
+ // private field in java.net.Socket$SocketOutputStream
private Socket parent;
-
- InetAddress getInetAddress() {
- throw new RuntimeException();
- }
-
- int getPort() {
- throw new RuntimeException();
- }
}