X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/baca9ce86a38dc54c4574890ee2d352fd81f78b2..61343b82c4f0da4c68e4c6373daafff4a81efdd1:/wp-admin/includes/class-wp-filesystem-ssh2.php?ds=sidebyside diff --git a/wp-admin/includes/class-wp-filesystem-ssh2.php b/wp-admin/includes/class-wp-filesystem-ssh2.php index 3114456e..8ff3cb18 100644 --- a/wp-admin/includes/class-wp-filesystem-ssh2.php +++ b/wp-admin/includes/class-wp-filesystem-ssh2.php @@ -184,8 +184,8 @@ class WP_Filesystem_SSH2 extends WP_Filesystem_Base { if ( ! $this->exists($file) ) return false; if ( ! $recursive || ! $this->is_dir($file) ) - return $this->run_command(sprintf('chgrp %o %s', $mode, escapeshellarg($file)), true); - return $this->run_command(sprintf('chgrp -R %o %s', $mode, escapeshellarg($file)), true); + return $this->run_command(sprintf('chgrp %s %s', escapeshellarg($group), escapeshellarg($file)), true); + return $this->run_command(sprintf('chgrp -R %s %s', escapeshellarg($group), escapeshellarg($file)), true); } function chmod($file, $mode = false, $recursive = false) { @@ -210,8 +210,8 @@ class WP_Filesystem_SSH2 extends WP_Filesystem_Base { if ( ! $this->exists($file) ) return false; if ( ! $recursive || ! $this->is_dir($file) ) - return $this->run_command(sprintf('chown %o %s', $mode, escapeshellarg($file)), true); - return $this->run_command(sprintf('chown -R %o %s', $mode, escapeshellarg($file)), true); + return $this->run_command(sprintf('chown %s %s', escapeshellarg($owner), escapeshellarg($file)), true); + return $this->run_command(sprintf('chown -R %s %s', escapeshellarg($owner), escapeshellarg($file)), true); } function owner($file) {