From 3733d0c6d09189c264b761fa923ae7469d4fc8be Mon Sep 17 00:00:00 2001 From: Lars Jung Date: Sun, 28 Jul 2013 16:15:20 +0200 Subject: [PATCH] Replace 'which' with 'command -v' to be POSIX compatible here. --- src/_h5ai/server/php/inc/App.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/_h5ai/server/php/inc/App.php b/src/_h5ai/server/php/inc/App.php index 77e97c06..f699a823 100644 --- a/src/_h5ai/server/php/inc/App.php +++ b/src/_h5ai/server/php/inc/App.php @@ -280,11 +280,11 @@ class App { } $exif = function_exists("exif_thumbnail"); $cache = @is_writable($this->get_cache_abs_path()); - $tar = @preg_match("/tar(.exe)?$/i", `which tar`) > 0; - $zip = @preg_match("/zip(.exe)?$/i", `which zip`) > 0; - $convert = @preg_match("/convert(.exe)?$/i", `which convert`) > 0; - $ffmpeg = @preg_match("/ffmpeg(.exe)?$/i", `which ffmpeg`) > 0; - $du = @preg_match("/du(.exe)?$/i", `which du`) > 0; + $tar = @preg_match("/tar(.exe)?$/i", `command -v tar`) > 0; + $zip = @preg_match("/zip(.exe)?$/i", `command -v zip`) > 0; + $convert = @preg_match("/convert(.exe)?$/i", `command -v convert`) > 0; + $ffmpeg = @preg_match("/ffmpeg(.exe)?$/i", `command -v ffmpeg`) > 0; + $du = @preg_match("/du(.exe)?$/i", `command -v du`) > 0; return array( "idx" => $this->app_abs_href . "server/php/index.php",