From aa983f379a65a580d6f2cd01098999b1bec6266f Mon Sep 17 00:00:00 2001 From: chenx221 Date: Sat, 13 Apr 2024 17:08:58 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=9C=A8linux=E4=B8=8A?= =?UTF-8?q?=E6=8C=82=E8=BD=BD=E7=82=B9=E8=8E=B7=E5=8F=96=E7=BB=93=E6=9E=9C?= =?UTF-8?q?=E5=90=8E=E6=9C=89=E5=A4=9A=E4=BD=99\n=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- utils/SystemInfoHelper.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/SystemInfoHelper.php b/utils/SystemInfoHelper.php index 30e23d4..f5932b7 100644 --- a/utils/SystemInfoHelper.php +++ b/utils/SystemInfoHelper.php @@ -304,7 +304,7 @@ class SystemInfoHelper } $this->mp_used = $this->mp_size - $this->mp_avail; } else { - $this->dataMountPoint = shell_exec("df -P \"" . $dataPath . "\" | awk 'NR==2{print $6}'"); + $this->dataMountPoint = trim(shell_exec("df -P \"" . $dataPath . "\" | awk 'NR==2{print $6}'")); $this->mp_fs = shell_exec("df -T \"" . $this->dataMountPoint . "\" | awk 'NR==2{print $2}'"); $this->mp_size = intval(shell_exec('df -k "' . $this->dataMountPoint . '" | awk \'NR==2{print $2}\'')); $this->mp_used = intval(shell_exec('df -k "' . $this->dataMountPoint . '" | awk \'NR==2{print $3}\''));