fix pretty size

git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@1819 2a923420-c742-0410-a762-8d5b09965624
This commit is contained in:
hummypkg
2014-03-03 17:30:17 +00:00
parent 9fd84a8938
commit 972eab191c
2 changed files with 4 additions and 3 deletions

View File

@@ -7,7 +7,8 @@ if {![exists -proc pretty_size]} {
set size $($size / 1024.0)
}
set size [string trimright [format "%.2f" $size] "0."]
set size [string trimright \
[string trimright [format "%.2f" $size] "0"] "."]
return "$size [lindex $units $i]"
}