>From 3d79893350675549f9df7644e3b413a4395f717d Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther
Date: Wed, 19 Jan 2011 17:02:53 +0100 Subject: [PATCH] sockets: Make ServerSocket fail if one attempts to bind the same port 2011-01-19 Holger Hans Peter Freyther * package.xml: Add TestCases.st as SUnit test. * Sockets.st: Use File checkError to check errno and not soError. * TestCases.st: Add file for SUnit test case. --- packages/sockets/AbstractSocketImpl.st | 2 +- packages/sockets/ChangeLog | 6 ++++++ packages/sockets/TestCases.st | 11 +++++++++++ packages/sockets/package.xml | 5 +++++ 4 files changed, 23 insertions(+), 1 deletions(-) create mode 100644 packages/sockets/TestCases.st diff --git a/packages/sockets/AbstractSocketImpl.st b/packages/sockets/AbstractSocketImpl.st index 992b7f6..9464cc7 100644 --- a/packages/sockets/AbstractSocketImpl.st +++ b/packages/sockets/AbstractSocketImpl.st @@ -112,7 +112,7 @@ this can be changed by class methods on SocketAddress sublcasses.'> [(self bind: fd to: addr - addrLen: addr size) < 0 ifTrue: [File checkError: self soError] ] + addrLen: addr size) < 0 ifTrue: [File checkError] ] ifCurtailed: [self close]. self isOpen ifTrue: [self hasBeenBound] ] diff --git a/packages/sockets/ChangeLog b/packages/sockets/ChangeLog index 20a9bc6..94de2c6 100644 --- a/packages/sockets/ChangeLog +++ b/packages/sockets/ChangeLog @@ -1,3 +1,9 @@ +2011-01-19 Holger Hans Peter Freyther + + * package.xml: Add TestCases.st as SUnit test. + * Sockets.st: Use File checkError to check errno and not soError. + * TestCases.st: Add file for SUnit test case. + 2010-12-04 Paolo Bonzini * package.xml: Remove now superfluous