mirror of
https://github.com/systemd/systemd.git
synced 2025-03-21 02:50:18 +03:00
[PATCH] get_dev_number() in extras/ide-devfs.sh
this patch corrects ide devices with number greater than 9 being linked into wrong discs/discX directories (my hda10 device was in discs/disc1 directory) it adds % into pattern for $DRIVE, so for example, hda10 is not eaten to hda1, but to hda, and break in for cycle works for it
This commit is contained in:
parent
786f923196
commit
c7e2a0bc08
@ -18,7 +18,7 @@ get_dev_number() {
|
||||
local x=
|
||||
local num=0
|
||||
local MEDIA=
|
||||
local DRIVE="${1%[0-9]*}"
|
||||
local DRIVE="${1%%[0-9]*}"
|
||||
|
||||
for x in /proc/ide/*/media; do
|
||||
if [ -e "${x}" ]; then
|
||||
|
Loading…
x
Reference in New Issue
Block a user