diff options
author | Matthew Thode <[email protected]> | 2013-11-06 16:56:50 -0600 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2013-11-08 10:55:20 -0800 |
commit | 760ec997dfde8cf7dcbe1f367456423668e0cf76 (patch) | |
tree | de7ce1b550f4f0276ce46231c814811b5590bbb9 /etc/init.d/zfs.gentoo.in | |
parent | fd4f76160cb34539f875781fe7f2dea4b937ace5 (diff) |
Updating init scripts to have more robust grepping
The previous pattern could accidentally match on things like
'real_root=ZFS=node02-zp00/ROOT/rootfs' due to the 'ZFS=no'
substring.
Signed-off-by: Matthew Thode <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #1837
Diffstat (limited to 'etc/init.d/zfs.gentoo.in')
-rw-r--r-- | etc/init.d/zfs.gentoo.in | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/etc/init.d/zfs.gentoo.in b/etc/init.d/zfs.gentoo.in index 0034e02ba..01a7731f7 100644 --- a/etc/init.d/zfs.gentoo.in +++ b/etc/init.d/zfs.gentoo.in @@ -5,7 +5,7 @@ if [ -z "$init" ]; then # Not interactive - grep -Eqi 'zfs=off|zfs=no' /proc/cmdline && exit 3 + grep -qE '(^|[^\\](\\\\)* )zfs=(off|no)( |$)' /proc/cmdline && exit 3 fi depend() |