Skip to content

Commit 29c5f93

Browse files
authored
Update v-list-sys-services
Printf work fine but fail whit some locales -> https://forum.vestacp.com/viewtopic.php?f=17&t=12585 In my test this work as well as printf but not is afected to locale problems.
1 parent f33ce7e commit 29c5f93

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bin/v-list-sys-services

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ get_srv_state() {
9999

100100
# Calculating memory usage
101101
mem=$(echo "$pids" |awk '{sum += $3} END {print sum/1024 }')
102-
mem=$(printf "%.0f\n" $mem)
102+
mem=$(echo "${mem%%.*}")
103103

104104
# Searching pid file
105105
pid_file=''

0 commit comments

Comments
 (0)