Bug 28867 - ServerSocket creates sockets which will not be closed.
Summary: ServerSocket creates sockets which will not be closed.
Status: RESOLVED FIXED
Alias: None
Product: classpath
Classification: Unclassified
Component: classpath (show other bugs)
Version: unspecified
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-28 04:44 UTC by Ito Kazumitsu
Modified: 2006-09-11 22:26 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments
Testcase (293 bytes, text/plain)
2006-08-28 04:46 UTC, Ito Kazumitsu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ito Kazumitsu 2006-08-28 04:44:54 UTC
java.net.ServerSocket creates a socket when its listening operation
is interuppted by SO_TIMEOUT, but that socket will never be closed.
This causes "too many open files" error in a long run.

A simple testcase will be submitted later.
Comment 1 Ito Kazumitsu 2006-08-28 04:46:47 UTC
Created attachment 12145 [details]
Testcase
Comment 2 cvs-commit@developer.classpath.org 2006-09-10 21:17:33 UTC
Subject: Bug 28867

CVSROOT:	/cvsroot/classpath
Module name:	classpath
Changes by:	Ito Kazumitsu <itokaz>	06/09/10 21:16:40

Modified files:
	.              : ChangeLog 
	java/net       : ServerSocket.java Socket.java 

Log message:
	2006-09-10  Ito Kazumitsu  <kaz@maczuka.gcd.org>
	
		Fixes bug #28867
		Originally in Kaffe: 2004-04-16  Helmer Kraemer <hkraemer@freenet.de>
		* java/net/ServerSocket.java(implAccept): Deleted socket.implCreated.
		* java/net/Socket.java: Avoid creating a redundant file descriptor.
		(implCreated): Deleted, (getImpl): Don't check impleCreated,
		(bind): Call getImpl().create(true).

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/classpath/ChangeLog?cvsroot=classpath&r1=1.8520&r2=1.8521
http://cvs.savannah.gnu.org/viewcvs/classpath/java/net/ServerSocket.java?cvsroot=classpath&r1=1.44&r2=1.45
http://cvs.savannah.gnu.org/viewcvs/classpath/java/net/Socket.java?cvsroot=classpath&r1=1.55&r2=1.56



Comment 3 Ito Kazumitsu 2006-09-11 22:26:00 UTC
Fixed.