usr/lib/byobu/disk_io: fix regex to support RAID devices, LP: #572855

This commit is contained in:
Dustin Kirkland 2010-05-03 07:23:36 -05:00
commit a98683767b
2 changed files with 2 additions and 2 deletions

2
debian/changelog vendored
View file

@ -1,6 +1,6 @@
byobu (2.74) unreleased; urgency=low byobu (2.74) unreleased; urgency=low
* UNRELEASED * usr/lib/byobu/disk_io: fix regex to support RAID devices, LP: #572855
-- Dustin Kirkland <kirkland@ubuntu.com> Wed, 28 Apr 2010 23:11:14 -0500 -- Dustin Kirkland <kirkland@ubuntu.com> Wed, 28 Apr 2010 23:11:14 -0500

View file

@ -26,7 +26,7 @@ case $MP in
/dev/*) disk="$MP" ;; /dev/*) disk="$MP" ;;
*) disk=$(grep -m 1 " $MP " /etc/mtab | sed -e "s: .*$::") ;; *) disk=$(grep -m 1 " $MP " /etc/mtab | sed -e "s: .*$::") ;;
esac esac
disk=$(echo "$disk" | sed -e "s: .*$::" -e "s:^.*/::" -e "s:[0-9]*$::") disk=$(echo "$disk" | sed -e "s: .*$::" -e "s:^.*/::" -e "s:\([hsv]d[a-z]\)[0-9]*$:\1:")
if [ "$1" = "--detail" ]; then if [ "$1" = "--detail" ]; then
if which iostat >/dev/null; then if which iostat >/dev/null; then