mirror of
https://github.com/gcc-mirror/gcc.git
synced 2026-05-06 14:59:39 +02:00
2004-03-21 Ito Kazumitsu <kaz@maczuka.gcd.org>
* java/net/ServerSocket.java
(accept): Close the socket when error occured.
From-SVN: r79774
This commit is contained in:
committed by
Michael Koch
parent
bdf11d5567
commit
de205e06ba
@@ -1,3 +1,8 @@
|
||||
2004-03-21 Ito Kazumitsu <kaz@maczuka.gcd.org>
|
||||
|
||||
* java/net/ServerSocket.java
|
||||
(accept): Close the socket when error occured.
|
||||
|
||||
2004-03-21 Jeroen Frijters <jeroen@frijters.net>
|
||||
|
||||
* java/net/URI.java (parseURI): Added unquoting.
|
||||
|
||||
@@ -323,7 +323,24 @@ public class ServerSocket
|
||||
sm.checkListen (impl.getLocalPort ());
|
||||
|
||||
Socket socket = new Socket();
|
||||
implAccept (socket);
|
||||
|
||||
try
|
||||
{
|
||||
implAccept(socket);
|
||||
}
|
||||
catch (IOException e)
|
||||
{
|
||||
try
|
||||
{
|
||||
socket.close();
|
||||
}
|
||||
catch (IOException e2)
|
||||
{
|
||||
}
|
||||
|
||||
throw e;
|
||||
}
|
||||
|
||||
return socket;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user