We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 576bd48 commit 5ecd14dCopy full SHA for 5ecd14d
webdav.php
@@ -132,15 +132,14 @@ public function stop() {
132
133
// Find all rclone webdav processes for the /home folder
134
$cmd = 'ps ax | grep "rclone serve webdav" | grep "/home" | grep -v grep';
135
- exec($cmd, $processes);
+ $processes = explode( PHP_EOL, shell_exec( $cmd ) );
136
137
// Loop through each process and extract the process ID (PID)
138
foreach ($processes as $process) {
139
$pid = preg_replace('/^\s*(\d+).*$/', '$1', $process);
140
141
// Kill the process
142
- $kill = "kill $pid";
143
- exec($kill, $output, $returnValue);
+ shell_exec( "kill $pid" );
144
145
global $hcpp;
146
$hcpp->log( "Killed rclone webdav process $pid" );
0 commit comments