Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/etc/rc.d Make it work with empty /var
details: https://anonhg.NetBSD.org/src/rev/49f744f3177e
branches: trunk
changeset: 975899:49f744f3177e
user: martin <martin%NetBSD.org@localhost>
date: Tue Sep 08 12:45:03 2020 +0000
description:
Make it work with empty /var
diffstat:
etc/rc.d/clearcritlocal | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diffs (22 lines):
diff -r 2e3cfba273ee -r 49f744f3177e etc/rc.d/clearcritlocal
--- a/etc/rc.d/clearcritlocal Tue Sep 08 10:30:17 2020 +0000
+++ b/etc/rc.d/clearcritlocal Tue Sep 08 12:45:03 2020 +0000
@@ -1,6 +1,6 @@
#!/bin/sh
#
-# $NetBSD: clearcritlocal,v 1.1 2020/07/22 16:50:41 martin Exp $
+# $NetBSD: clearcritlocal,v 1.2 2020/09/08 12:45:03 martin Exp $
#
# REQUIRE: mountcritlocal
@@ -18,7 +18,9 @@
# this could include the cleanup of lock files and /var/run, etc.
#
rm -f /etc/nologin /var/spool/lock/LCK.*
- test -d /var/run && (cd /var/run && rm -rf -- *)
+ if [ -d /var/run ]; then
+ cd /var/run && rm -rf -- *
+ fi
return 0
}
Home |
Main Index |
Thread Index |
Old Index