discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Application launching and pasteboard slow down


From: Fred Kiefer
Subject: Re: Application launching and pasteboard slow down
Date: Thu, 18 Apr 2002 01:38:27 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; de-DE; rv:0.9.4) Gecko/20011019 Netscape6/6.2

Since this change gdnc is no longer working on my Windows 2000 machine, even after rebuilding GNUstep. When I start an application it cannot connect to the already running gdnc and starts a new one and keeps on doing this for each notification it is trying to send. This gets a bit annoying as it also pops up a window to tell my that it cannot contact gdnc.
gdomap seems to work and there is only one running at any time.

Fred

Richard Frith-Macdonald wrote:

I have added an autoconf check for the SO_REUSEADDR bug in the base library,
and modified the networking code to use the simple workaround of not using
SO_REUSEADDR on systems where it is broken (windoze, some FreeBSDs, and some
versions of Solaris AFAIK).

Explanation of the bug ... the SO_REUSEADDR option is set on a network socket
to say that, if the socket is in a TIME_WAIT state (ie it has recently been
closed, but the handshake for the close with the other end of the socket has not been completed) then the socket address/port may be re-used immediately. This permits a service to be restarted on the same address/port without having
to wait for the (typically 1 to 4 minute) timeout.

On some systems (windoze, some versions of FreeBSD, some of Solaris, and perhaps a few others), using SO_REUSEADDR actually permits the address/port to be re-used
*no-matter-what-state-it's-in*.
This has two effects -
1. a security issue - since other processes can bind to the same address
as your process and steal packets.
2. more importantly for us, we can't attempt to bind to an address/port in
order to find out if there is already a process using it - our bind attempt
will succeed when it really shouldn't. This means that you can start multiple
copies of servers using the same name ... since the nameserver process will
always think that the old server has died.

Not using SO_REUSEADDR  will leave most networking unaffected, but if a
gdomap process is killed, it will not be able to restart until the system
timeout has expired.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]