Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 Sep 2010 14:01:29 +0200
From:      Lars Engels <lars.engels@0x20.net>
To:        Dmitry Banshchikov <ubique@peterhost.ru>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: little mistake in rc.subr?
Message-ID:  <20100927120129.GF95673@e.0x20.net>
In-Reply-To: <20100927150421.260874f0@amnesiac.pht>
References:  <20100927150421.260874f0@amnesiac.pht>

next in thread | previous in thread | raw e-mail | index | archive | help

--ylS2wUBXLOxYXZFQ
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Sep 27, 2010 at 03:04:21PM +0400, Dmitry Banshchikov wrote:
> Hello,
>=20
> In /etc/rc.subr, at line 231, there is:
>=20
> if [ ! -f $_pidfile ]; then
> debug "pid file ($_pidfile): not readable."
>     return
> fi
>=20
> Is check "[ ! -r $_pidfile ]" more correct?

There's pratically no difference. rc stuff is run as root, so if there's
a file, it's readable, if there's no file, then the debug message is
printed.

--ylS2wUBXLOxYXZFQ
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (FreeBSD)

iEYEARECAAYFAkygh5kACgkQKc512sD3afi4sQCgmxlKG3nCWUc696Z9j8vEdJqR
6vcAn3ycCyEtWPX6t2OFNJOvaIeJNsr3
=G5Zo
-----END PGP SIGNATURE-----

--ylS2wUBXLOxYXZFQ--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100927120129.GF95673>