On Fri, Dec 24, 1999 at 11:05:35AM +1100, Peter Jeremy wrote:
> >>That said, the error message should have been:
> >> test: ]: unexpected operator
> >>and it is not clear why you are getting `[' reported as the program
> >>name.
> >
> >Well, /bin/test and /bin/[ are links to the same inode:
>
> Agreed, but the error message is printed by errx(3). errx(3) prints
> __progname (which is effectively equivalent to argv[0]) as the program
> name - ie the name by which the program was invoked.
>
> test(1) includes a check near the beginning to see it it was invoked as
> `[' and if it was it checks to see that the last argument is `]' and
> deletes it if it was. In both cases, the remaining arguments are then
> passed to the expression evaluator.
Why I did an original post is because it appeared that my cron job doesn't
work any more:
Date: Sun, 26 Dec 1999 01:30:01 +0300 (MSK)
From: [EMAIL PROTECTED] (Cron Daemon)
To: [EMAIL PROTECTED]
Subject: Cron <vlad@hq> /bin/[ -f /var/run/INET ] && /usr/local/bin/fetchmail
>From [EMAIL PROTECTED] Sun Dec 26 01:30:03 1999
[: ]: unexpected operator
It _did_ work before. I put your attention that you'd try using /bin/[, not
just [ (as someone on this list did). The latter is executed by shell, obviously.
Judjed by my logs the last change to /bin/test was on Dec, 16 or somewhere
about.
--
Vlad Skvortsov, [EMAIL PROTECTED]
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-stable" in the body of the message