rnews processes sleeping on connect
Russ Allbery
rra at stanford.edu
Sun Dec 11 23:34:27 UTC 2005
Nick Burrett <nick at sqrt.co.uk> writes:
> INN version 2.4.1, destination news server is INN 2.4.0.
> The use of 'fgets' in lib/remopen.c::NNTPconnect() occasionally gets
> stuck whilst waiting for a reponse string from the news server, during a
> run of 'rnews':
[...]
> Would it not be better to simply to use the unbuffered read() function
> directly on the socket descriptor rather than buffering through stdio ?
> At least in the case of the former, we could apply better timeouts to
> the read operations, or close off a read-operation quicker if we start
> to receive unexpected information.
The hard part of this is that then the read needs to be repeated until we
see a newline. However, I think that should be possible to do without too
much trouble. I'll look at making that change.
The right long-term solution is to use the new NNTP library, but that's a
bigger change.
Thanks for the report!
--
Russ Allbery (rra at stanford.edu) <http://www.eyrie.org/~eagle/>
More information about the inn-bugs
mailing list