rnews
Matt McLeod
matt at boggle.org
Tue Nov 7 07:19:54 UTC 2000
Russ wibbled thus:
> Matt McLeod <matt at boggle.org> writes:
>
> > I'm going to try and start helping out with INN. As a start, I'd like
> > to have a go at this item from TODO:
>
> > * rnews currently rejects articles with lines ending in CRLF, according to
> > one report. This should be checked, and if true, it should be more
> > flexible about line endings.
>
> > Any objections?
>
> Have at it! Thanks!
I can't believe it's taken me this long to actually get around to
looking at this. Aargh.
Anyway. The problem definately exists, though it's more one of
not special-casing \r\n than anything else -- rnews is quite happily
passing the extraneous \r along to innd, which isn't happy about that.
For example, throwing an article with CRLF-terminated lines at rnews
results in:
Nov 7 17:55:42 megumi innd: localhost:17 bad_messageid <yln1fcibpc.boo at windlord.stanford.edu>
(Yeah, I was lazy and grabbed the first incoming article I saw to play
with, which just happened to be one of yours. Pure coincidence.)
Modifying the article so that the message-id is not CRLF terminated
then results in an "unwanted newsgroup" error.
The obvious solution to me would be to stick something in
ReadRemainder() to throw out any \r it finds. My C is rusty,
but I'm happy to give it a go (though the result will probably
not be too pretty). The "easy" way, I guess, would be to change
ReadRemainder() so it only ever reads a single character at a time,
then look at that character and junk it if it's a \r. But
presumably that would not be nice for performance, so something
more complicated is probably in order.
(This all presumes that the extra \r isn't causing a problem for
the actual unbatching -- I don't *think* it is, but ICBW.)
Matt
--
Mistakes are often the stepping stones to utter failure.
More information about the inn-workers
mailing list