Article View: news.software.nntp
Article #31273Re: does "." terminate server articles?
From: Fluffy
Date: Wed, 09 Sep 1998 00:00
Date: Wed, 09 Sep 1998 00:00
26 lines
1962 bytes
1962 bytes
Meow meow John Savage meow meow meow rookswood@suburbian.com.au meow Kitty? > I've stumbled upon an article that doesn't end with a single dot; i.e., > it doesn't end with J.J where J signifies the ctrl-J character, so > my script's [[ "$xline" == . ]] test fails and the script hangs. :( Yes, the dot is added by the server, and yes, you were loking for the wrong stuff. The actual terminator is 'CRLF.CRLF' (CRLF is ^M^J) although if you are grabbing news through a telnet session, it will usually be converted for you to just 'LF.LF'. A lot of things, including options negotiation, can cause the variance you saw. The answer on how to fix it is to use a "real" programming language to open a socket and interpret the characters correctly (telnet can get mightily confused by some of the things that may appear in news articles), or use one of the already-written packages like newsx or suck for this purpose. If you do decide to roll your own replacement in C or perl or whatever, read through RFC 977 instead of relying on what you think you see coming down the pipe. Sometimes, telnet "lies."
Technical Details
Message-ID:
<EyztGJ.317@fluffy.meow.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mailReferences:
<980909000111114.09Sep98$rookswood@suburbian.com>Show Full Headers
Complete Article Headers
Message-ID: <EyztGJ.317@fluffy.meow.org> Subject: Re: does "." terminate server articles? Date: Wed, 09 Sep 1998 00:00:00 +0000 From: fluffy@meow.org (Fluffy) References: <980909000111114.09Sep98$rookswood@suburbian.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mail X-Deja-AN: 389232019 Mail-Copies-To: never X-Complaints-To: abuse@demon.net X-Mail2News-Path: news.demon.net!fluffy.meow.org X-Trace: mail2news.demon.co.uk 905304567 mail2news:13546 mail2news mail2news.demon.co.uk Organization: Ruler of All Usenet (on sabbatical) X-P-Meow: Meow Newsgroups: news.software.readers,news.software.nntp