summaryrefslogtreecommitdiffstats
path: root/system/libraries/Upload.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2011-10-04 17:27:32 +0200
committerPhil Sturgeon <email@philsturgeon.co.uk>2011-10-27 00:35:53 +0200
commitc5efd10679a7b7b4010cd6cc30bd976d3fe8c1ef (patch)
tree303544328218cd070c4e2258af473c3476ef0e40 /system/libraries/Upload.php
parentdcfee7103408416329c42f376d23fb3c88d4cffc (diff)
Change Windows OS detection approach
Diffstat (limited to 'system/libraries/Upload.php')
-rw-r--r--system/libraries/Upload.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/system/libraries/Upload.php b/system/libraries/Upload.php
index a0f3e76bb..05511b5d3 100644
--- a/system/libraries/Upload.php
+++ b/system/libraries/Upload.php
@@ -1052,7 +1052,7 @@ class CI_Upload {
* - a 'W' in the substr() expression bellow, would mean that we're using Windows
* - many system admins would disable the exec() function due to security concerns, hence the function_exists() check
*/
- if (substr(PHP_OS, 0, 1) !== 'W' && function_exists('exec'))
+ if (DIRECTORY_SEPARATOR !== '\\' && function_exists('exec'))
{
$output = array();
@exec('file --brief --mime-type ' . escapeshellarg($file['tmp_path']), $output, $return_code);