Article View: news.software.nntp
Article #81851Re: mailpost exits with 0 when it should not
From: Jon Bendtsen
Date: Wed, 02 Sep 2009 12:34
Date: Wed, 02 Sep 2009 12:34
20 lines
1700 bytes
1700 bytes
Ray Banana wrote: > * Jon Bendtsen wrote: > >> cat "$post" | /usr/lib/news/bin/mailpost -a approved $group && rm >> "$post" >> So it should ONLY delete mails that was successfully posted, which >> leads to mailpost should not return 0 when there was an error. > > It's not the return code from mailpost that triggers the rm command, > but the return code from cat and cat was successful. Are you sure about that? true | false && echo "hello world" gives no output, where as false | true && echo "hello world" does give output JonB
Technical Details
Message-ID:
<h7loog$aae$2@munin.diku.dk>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!border1.nntp.ams.giganews.com!nntp.giganews.com!goblin3!goblin2!goblin.stu.neva.ru!news.net.uni-c.dk!munin.diku.dk!not-for-mailReferences:
<h7lkqm$947$1@munin.diku.dk> <slrnh9sn2v.jut.rayban@banana.shacknet.nu>Show Full Headers
Complete Article Headers
Message-ID: <h7loog$aae$2@munin.diku.dk> Subject: Re: mailpost exits with 0 when it should not Date: Wed, 02 Sep 2009 14:34:24 +0200 From: Jon Bendtsen <noone@example.com> References: <h7lkqm$947$1@munin.diku.dk> <slrnh9sn2v.jut.rayban@banana.shacknet.nu> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!border1.nntp.ams.giganews.com!nntp.giganews.com!goblin3!goblin2!goblin.stu.neva.ru!news.net.uni-c.dk!munin.diku.dk!not-for-mail Newsgroups: news.software.nntp Organization: Department of Computer Science, University of Copenhagen Lines: 20 NNTP-Posting-Host: tyr.diku.dk Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Trace: munin.diku.dk 1251894864 10574 130.225.96.226 (2 Sep 2009 12:34:24 GMT) X-Complaints-To: news@diku.dk NNTP-Posting-Date: Wed, 2 Sep 2009 12:34:24 +0000 (UTC) User-Agent: Thunderbird 2.0.0.23 (Macintosh/20090812) In-Reply-To: <slrnh9sn2v.jut.rayban@banana.shacknet.nu>