summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2004-08-25 14:32:59 +0000
committerMike Frysinger <vapier@gentoo.org>2004-08-25 14:32:59 +0000
commitadff9a5fbfe19a2405086fcc333809b9d206344b (patch)
tree1c35d1f16175dab6991f418a1e24b3886c3a10a4 /net-misc/ntp
parentfirewall friendly defaults (Manifest recommit) (diff)
downloadgentoo-2-adff9a5fbfe19a2405086fcc333809b9d206344b.tar.gz
gentoo-2-adff9a5fbfe19a2405086fcc333809b9d206344b.tar.bz2
gentoo-2-adff9a5fbfe19a2405086fcc333809b9d206344b.zip
small sanity check in case machine doesnt have the ntp accounts
Diffstat (limited to 'net-misc/ntp')
-rw-r--r--net-misc/ntp/files/ntpd.rc7
1 files changed, 5 insertions, 2 deletions
diff --git a/net-misc/ntp/files/ntpd.rc b/net-misc/ntp/files/ntpd.rc
index 46e317694764..37a6788095c2 100644
--- a/net-misc/ntp/files/ntpd.rc
+++ b/net-misc/ntp/files/ntpd.rc
@@ -1,7 +1,7 @@
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/ntp/files/ntpd.rc,v 1.19 2004/07/15 00:05:46 agriffis Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/ntp/files/ntpd.rc,v 1.20 2004/08/25 14:32:59 vapier Exp $
depend() {
need net
@@ -23,7 +23,10 @@ start() {
ebegin "Starting ntpd"
touch /var/run/ntpd.pid
- chown ntp:ntp /var/run/ntpd.pid
+ if ! chown ntp:ntp /var/run/ntpd.pid ; then
+ eend 1 "unable to chown pid file"
+ return 1
+ fi
/usr/bin/ntpd -p /var/run/ntpd.pid ${NTPD_OPTS}
eend $? "Failed to start ntpd"
}