SVN: rc-scripts/trunk/rc.d: rc.shutdown rc.sysinit
glen
glen at pld-linux.org
Fri Nov 9 02:37:34 CET 2007
Author: glen
Date: Fri Nov 9 02:37:34 2007
New Revision: 9031
Modified:
rc-scripts/trunk/rc.d/rc.shutdown
rc-scripts/trunk/rc.d/rc.sysinit
Log:
- /etc/crypttab shouldn't be empty when using it
Modified: rc-scripts/trunk/rc.d/rc.shutdown
==============================================================================
--- rc-scripts/trunk/rc.d/rc.shutdown (original)
+++ rc-scripts/trunk/rc.d/rc.shutdown Fri Nov 9 02:37:34 2007
@@ -145,7 +145,7 @@
_rebootwhat="vserver"
fi
-if [ -f /etc/crypttab ]; then
+if [ -f /etc/crypttab ] && ! is_empty_file /etc/crypttab; then
. /etc/rc.d/init.d/cryptsetup
show "Stopping disk encryption"
Modified: rc-scripts/trunk/rc.d/rc.sysinit
==============================================================================
--- rc-scripts/trunk/rc.d/rc.sysinit (original)
+++ rc-scripts/trunk/rc.d/rc.sysinit Fri Nov 9 02:37:34 2007
@@ -268,7 +268,7 @@
TIME_SETUP_DELAYED=yes
fi
- if [ -f /etc/crypttab ]; then
+ if [ -f /etc/crypttab ] && ! is_empty_file /etc/crypttab; then
# XXX might need modules dep
# Device mapper & related initialization
if ! fgrep -q device-mapper /proc/devices; then
@@ -432,7 +432,7 @@
done
fi
- if [ -f /etc/crypttab ]; then
+ if [ -f /etc/crypttab ] && ! is_empty_file /etc/crypttab; then
# XXX, this must be probably done after random is initialized from /var/run/random-seed
show "Starting disk encryption using the RNG:"
init_crypto 1 && ok || fail
More information about the pld-cvs-commit
mailing list