Make sure apache_getenv() exists before using it. fixes #6278

git-svn-id: http://svn.automattic.com/wordpress/trunk@7401 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
markjaquith 2008-03-19 18:18:59 +00:00
parent 5132af64c4
commit c6fa4c36ee
1 changed files with 1 additions and 1 deletions

View File

@ -779,7 +779,7 @@ function media_upload_form( $errors = null ) {
$flash_action_url = get_option('siteurl') . "/wp-admin/async-upload.php";
// If Mac and mod_security, no Flash. :(
if ( false !== strpos(strtolower($_SERVER['HTTP_USER_AGENT']), 'mac') && 'on' == strtolower(apache_getenv('MODSEC_ENABLE')) )
if ( function_exists('apache_getenv') && false !== strpos(strtolower($_SERVER['HTTP_USER_AGENT']), 'mac') && 'on' == strtolower(apache_getenv('MODSEC_ENABLE')) )
$flash = false;
else
$flash = true;