Subject: Re: do you use sysutils/amanda-common and chg-disk changer?
To: None <tech-pkg@NetBSD.org>
From: Jukka Salmi <email@example.com>
Date: 10/11/2004 23:33:49
David Laight --> tech-pkg (2004-10-11 20:55:58 +0100):
> On Mon, Oct 11, 2004 at 08:33:06PM +0200, Manuel Bouyer wrote:
> > On Mon, Oct 11, 2004 at 11:18:36AM -0700, Jeremy C. Reed wrote:
> > > Please see PR pkg/27207
> > > http://www.NetBSD.org/cgi-bin/query-pr-single.pl?number=27207
> > >
> > > The chg-disk shell script is not portable and a patch is provided above.
> > >
> > > If you use sysutils/amanda-common and chg-disk please test it with some
> > > different /bin/sh shells (like bash, sh and ksh).
> > >
> > > The patch looks fine to me. But I don't use amanda.
> > The patch looks fine for me too, but it should go in amanda-server, not
> > amanda-common.
> $(($xxx + 1)) is valid on most modern (posix) shells, and saves a fork/exec.
That's what I was using until I noticed that the problem was already
fixed in Amanda 2.4.4p3 with using `expr $xxx + 1`. The commit
message is just "Fix for sh compatibility.", I don't know why they
use an external program. But accepting this saves us a patch when the
Amanda pkgsrc package is updated...
$ ((RANDOM%6)) || rm -rf ~