From 0274dcba575272585a6f0b16bc777301f9458537 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Tue, 25 Nov 2014 11:06:26 +0100 Subject: Replace some more "command -v" calls with the Helper method --- apps/files_external/lib/smb.php | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'apps') diff --git a/apps/files_external/lib/smb.php b/apps/files_external/lib/smb.php index 6e53c4a9931..3f0b0f45bfb 100644 --- a/apps/files_external/lib/smb.php +++ b/apps/files_external/lib/smb.php @@ -139,13 +139,8 @@ class SMB extends \OC\Files\Storage\StreamWrapper{ * check if smbclient is installed */ public static function checkDependencies() { - if (function_exists('shell_exec')) { - $output=shell_exec('command -v smbclient 2> /dev/null'); - if (!empty($output)) { - return true; - } - } - return array('smbclient'); + $smbClientExists = (bool) \OC_Helper::findBinaryPath('smbclient'); + return $smbClientExists ? true : array('smbclient'); } } -- cgit v1.2.3