From: Michael Prokop Date: Wed, 25 Jul 2007 17:27:18 +0000 (+0200) Subject: Fix code regression of checkbootparam X-Git-Tag: 0.7.11~1 X-Git-Url: http://git.grml.org/?p=grml-autoconfig.git;a=commitdiff_plain;h=f2e718518cd811284a9b14a67fe3978deaa5a378 Fix code regression of checkbootparam --- diff --git a/autoconfig.functions b/autoconfig.functions index f63815a..317323c 100755 --- a/autoconfig.functions +++ b/autoconfig.functions @@ -996,12 +996,12 @@ fi config_fstab(){ NOSWAP="yes" # we do not use swap by default! -if checkbootparam "swap" -o checkbootparam "anyswap" ; then +if checkbootparam "swap" || checkbootparam "anyswap" ; then NOSWAP='' checkbootparam "anyswap" && export ANYSWAP='yes' || export ANYSWAP="" fi -if checkbootparam "nofstab" -o checkbootparam "forensic" ; then +if checkbootparam "nofstab" || checkbootparam "forensic" ; then ewarn "Skipping /etc/fstab creation as requested on boot commandline." ; eend 0 else einfo "Scanning for harddisk partitions and creating /etc/fstab. (Disable this via boot option: nofstab)" @@ -1758,7 +1758,7 @@ fi } config_automount(){ -if checkbootparam noautoconfig -o checkbootparam forensic ; then +if checkbootparam noautoconfig || checkbootparam forensic ; then ewarn "Skipping running automount of device(s) labeled GRMLCFG as requested." ; eend 0 else if [ -z "$INSTALLED" ] ; then @@ -2039,8 +2039,8 @@ fi config_swraid(){ if [ -z "$INSTALLED" ] ; then # notice: checkbootparam "forensic" is just for users who don't know how to really use the bootoption - if checkbootparam 'noraid' -o checkbootparam 'noswraid' -o \ - checkbootparam 'forensic' -o checkbootparam 'raid=noautodetect' ; then + if checkbootparam 'noraid' || checkbootparam 'noswraid' -o \ + checkbootparam 'forensic' || checkbootparam 'raid=noautodetect' ; then ewarn "Skipping SW-RAID code as requested on boot commandline." ; eend 0 else if ! [ -x /sbin/mdadm ] ; then @@ -2180,7 +2180,7 @@ fi # {{{ check for broken ipw3945 driver which causes problems (especially on hd install) config_ipw3945() { if grep -q ipw3945 /proc/modules ; then - if ! iwconfig 2>/dev/null| grep -q 'IEEE 802' ; then + if ! iwconfig 2>/dev/null| grep -qe 'IEEE 802' -qe 'unassociated' ; then ewarn "Broken ipw3945 network interface found, reloading module." rmmod ipw3945 modprobe ipw3945 diff --git a/debian/changelog b/debian/changelog index 6e0ebc7..52ecd90 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,6 +3,7 @@ grml-autoconfig (0.7.11) unstable; urgency=low * Rename bootoption splash into "textsplash" (and additionally support "tsplash" as well) so users can use graphical splash from Debian *or* textsplash of grml. + * Fix code regression of checkbootparam (use '||' instead of '-o') -- Michael Prokop Wed, 25 Jul 2007 19:12:56 +0200 diff --git a/grml-autoconfig b/grml-autoconfig index 8c2ba7e..1686c63 100755 --- a/grml-autoconfig +++ b/grml-autoconfig @@ -63,7 +63,7 @@ CMDLINE="$(cat /proc/cmdline)" checkvalue $CONFIG_DEBUG && config_debug SPLASH='' -if checkbootparam "textsplash" -o checkbootparam "tsplash"; then +if checkbootparam "textsplash" || checkbootparam "tsplash"; then SPLASH=1 fi