Comment 0 for bug 1222

Revision history for this message
Ralph Corderoy (ralph-inputplus) wrote :

On a fresh 5.04 install I `apt-get install sn' giving version 0.3.8-3. Since then, I've done no further sn configuration, including adding no newsgroups. I'm receiving daily complaints from cron:

    From: Anacron <email address hidden>
    To: <email address hidden>
    Subject: Anacron job 'cron.daily' on blake
    Date: Tue, 28 Jun 2005 08:23:01 +0100 (BST)

    /etc/cron.daily/sn:
    snexpire:* is not a valid newsgroup
    run-parts: /etc/cron.daily/sn exited with return code 1

It's because /etc/cron.daily/sn does

    cd /var/spool/sn
    ...
    for f in *
    do
    ...
                        /usr/sbin/snexpire -$EXPIRETIME $f

and since /var/spool/sn is empty the `*' gets passed to snexpire.

One solution would be to

    ls |
    while read f; do
        ...
    done

instead.