mirror of
https://github.com/smxi/inxi.git
synced 2024-11-16 16:21:39 +00:00
bug fix on disk size handling, some vm disk use the start number 252 in /proc/partitions, inxi failed to handle that, and so failed to
show proper disk size in virtual machine. New tarball/version number.
This commit is contained in:
parent
f60b86253f
commit
4e82d9b4d9
13
inxi
13
inxi
|
@ -1,8 +1,8 @@
|
|||
#!/bin/bash
|
||||
########################################################################
|
||||
#### Script Name: inxi
|
||||
#### version: 1.8.25
|
||||
#### Date: December 21 2012
|
||||
#### version: 1.8.26
|
||||
#### Date: December 22 2012
|
||||
#### Patch Number: 00
|
||||
########################################################################
|
||||
#### SPECIAL THANKS
|
||||
|
@ -4414,7 +4414,8 @@ get_hdd_data_basic()
|
|||
# size += $3
|
||||
# }
|
||||
# special case from this data: 8 0 156290904 sda
|
||||
$1 ~ /^(3|22|33|8)$/ && $NF ~ /[hsv]d[a-z]$/ && ( $2 % 16 == 0 || $2 % 16 == 8 ) {
|
||||
# note: vm has 252 known starter
|
||||
$1 ~ /^(3|8|22|33|252)$/ && $NF ~ /[hsv]d[a-z]$/ && ( $2 % 16 == 0 || $2 % 16 == 8 ) {
|
||||
size += $3
|
||||
}
|
||||
|
||||
|
@ -4435,8 +4436,10 @@ get_hdd_data_basic()
|
|||
else {
|
||||
print "NA,-" # print an empty array, this will be further handled in the print out function
|
||||
}
|
||||
}' $FILE_PARTITIONS ) )
|
||||
log_function_data 'cat' "$FILE_PARTITIONS"
|
||||
}' $FILE_PARTITIONS
|
||||
) )
|
||||
|
||||
log_function_data 'cat' "$FILE_PARTITIONS"
|
||||
fi
|
||||
IFS="$ORIGINAL_IFS"
|
||||
temp_array=${A_HDD_DATA[@]}
|
||||
|
|
Loading…
Reference in a new issue