mirror of
https://github.com/smxi/inxi.git
synced 2024-11-16 16:21:39 +00:00
small bug fix with null partitions array print out
This commit is contained in:
parent
a1d4e0be88
commit
b49c7fa48b
13
inxi
13
inxi
|
@ -8908,6 +8908,7 @@ get_weather_data()
|
|||
|
||||
# args: $1 - string to strip color code characters out of
|
||||
# returns count of string length minus colors
|
||||
# note; this cleanup may not be working on bsd sed
|
||||
calculate_line_length()
|
||||
{
|
||||
local string=$1
|
||||
|
@ -10526,14 +10527,14 @@ print_networking_ip_data()
|
|||
if_string=''
|
||||
fi
|
||||
else
|
||||
if [[ $( calculate_line_length "$if_string_holding$if_string" ) -lt $COLS_INNER ]];then
|
||||
if_string_holding="$if_string_holding$if_string"
|
||||
else
|
||||
if [[ $( calculate_line_length "$if_string_holding$if_string" ) -gt $COLS_INNER ]];then
|
||||
if [[ -n $if_string_holding ]];then
|
||||
full_string=$( create_print_line " " "$if_string_holding${CN}" )
|
||||
print_screen_output "$full_string"
|
||||
fi
|
||||
if_string_holding="$if_string"
|
||||
else
|
||||
if_string_holding="$if_string_holding$if_string"
|
||||
fi
|
||||
fi
|
||||
((i++))
|
||||
|
@ -10843,8 +10844,10 @@ print_partition_data()
|
|||
else
|
||||
line_starter=' '
|
||||
fi
|
||||
partition_data=$( create_print_line "$line_starter" "${a_partition_data[$i]}${CN}" )
|
||||
print_screen_output "$partition_data"
|
||||
if [[ -n ${a_partition_data[$i]} ]];then
|
||||
partition_data=$( create_print_line "$line_starter" "${a_partition_data[$i]}${CN}" )
|
||||
print_screen_output "$partition_data"
|
||||
fi
|
||||
done
|
||||
|
||||
eval $LOGFE
|
||||
|
|
Loading…
Reference in a new issue