From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,8bcfc803cebb8a9f,start X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1994-07-21 00:25:36 PST Path: nntp.gmd.de!Germany.EU.net!EU.net!uunet!munnari.oz.au!ariel.ucs.unimelb.EDU.AU!ucsvc.ucs.unimelb.edu.au!lugb!misty!ccvj Newsgroups: comp.unix.osf.osf1 Subject: sort bug? Message-ID: <1994Jul20.234101.5587@lugb.latrobe.edu.au> From: ccvj@misty.latrobe.edu.au (Vicki Jordan) Date: Wed, 20 Jul 1994 23:41:01 GMT Sender: news@lugb.latrobe.edu.au (USENET News System) Organization: La Trobe University One of the daily news reports performs some operations on the log file such as: egrep unapproved $sus | sed 's/.*`\(.*\)'"'"'.*/\1/' | sort | uniq -c | sort -nr | sed 5q >$tmp egrep 'no subscribed' $sus | sed 's/.*`\(.*\)'"'"'.*/\1/' | sort | uniq -c | sort -nr | sed 5q >$tmp When the search is empty, sort generates a newline : sort: Warning: A newline character was added to the end of the input. sort: Warning: A newline character was added to the end of the input. This results in a fairly stupid looking report... top five supposedly-moderated groups with unmoderated postings: 1 " leading five unsubscribed newsgroups: 1 " Question: Is this a bug or a feature? -- Vicki Jordan V.Jordan@latrobe.edu.au Computing Services phone: +61 03 479 1500 La Trobe University fax: +61 03 479 1999 Bundoora Vic 3083 Australia