Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP2:GA
dracut.4966
0175-dracut-Fix-bad-array-subscript-messages.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0175-dracut-Fix-bad-array-subscript-messages.patch of Package dracut.4966
From b683b230c15d6058367499fa4dc7027ab30a9542 Mon Sep 17 00:00:00 2001 From: Marcus Meissner <meissner@suse.com> Date: Fri, 6 Feb 2015 12:52:29 +0100 Subject: dracut: Fix 'bad array subscript messages Fix "bad array subscript" messages when adding kernel modules using "/etc/dracut.conf". References: bsc#911660 Signed-off-by: Marcus Meissner <meissner@suse.com> --- dracut-functions.sh | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/dracut-functions.sh b/dracut-functions.sh index 6a58957..338714c 100755 --- a/dracut-functions.sh +++ b/dracut-functions.sh @@ -1428,7 +1428,7 @@ install_kmod_with_fw() { if [[ $omit_drivers ]]; then local _kmod=${1##*/} - _kmod=${_kmod%.ko} + _kmod=${_kmod%.ko*} _kmod=${_kmod/-/_} if [[ "$_kmod" =~ $omit_drivers ]]; then dinfo "Omitting driver $_kmod" @@ -1442,7 +1442,7 @@ install_kmod_with_fw() { if [[ $silent_omit_drivers ]]; then local _kmod=${1##*/} - _kmod=${_kmod%.ko} + _kmod=${_kmod%.ko*} _kmod=${_kmod/-/_} [[ "$_kmod" =~ $silent_omit_drivers ]] && return 0 [[ "${1##*/lib/modules/$kernel/}" =~ $silent_omit_drivers ]] && return 0 @@ -1576,7 +1576,7 @@ module_is_host_only() { local _mod=$1 local _modenc a i _k _s _v _aliases _mod=${_mod##*/} - _mod=${_mod%.ko} + _mod=${_mod%.ko*} _modenc=${_mod//-/_} [[ " $add_drivers " == *\ ${_mod}\ * ]] && return 0 @@ -1664,17 +1664,17 @@ instmods() { _mod=${_mod##*/} # Check for aliased modules _modalias=$(modinfo -k $kernel -F filename $_mod 2> /dev/null) - _modalias=${_modalias%.ko} + _modalias=${_modalias%.ko*} [[ -z "$_modalias" ]] && return 1 - if [ "${_modalias##*/}" != "$_mod" ] ; then + if [ "${_modalias##*/}" != "${_mod%.ko*}" ] ; then _mod=${_modalias##*/} fi # if we are already installed, skip this module and go on # to the next one. if [[ $DRACUT_KERNEL_LAZY_HASHDIR ]] && \ - [[ -f "$DRACUT_KERNEL_LAZY_HASHDIR/${_mod%.ko}.ko" ]]; then - read _ret <"$DRACUT_KERNEL_LAZY_HASHDIR/${_mod%.ko}.ko" + [[ -f "$DRACUT_KERNEL_LAZY_HASHDIR/${_mod%.ko*}" ]]; then + read _ret <"$DRACUT_KERNEL_LAZY_HASHDIR/${_mod%.ko*}" return $_ret fi @@ -1704,7 +1704,7 @@ instmods() { ((_ret+=$?)) else if [[ $DRACUT_KERNEL_LAZY_HASHDIR ]] && [ -n "$_mod" ]; then - echo $_mod >> "$DRACUT_KERNEL_LAZY_HASHDIR/lazylist" + echo ${_mod%.ko*} >> "$DRACUT_KERNEL_LAZY_HASHDIR/lazylist" for suse_mod_dep in ${suse_mod_deps["$_mod"]}; do echo $suse_mod_dep >> "$DRACUT_KERNEL_LAZY_HASHDIR/lazylist" done -- 1.8.4.5
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor