Avoid set_time_limit error supression
This commit is contained in:
parent
28c75c63dc
commit
47c47ab93c
|
@ -75,7 +75,9 @@ class WC_Tax_Rate_Importer extends WP_Importer {
|
|||
if ( function_exists( 'gc_enable' ) ) {
|
||||
gc_enable();
|
||||
}
|
||||
@set_time_limit(0);
|
||||
if ( function_exists( 'set_time_limit' ) && false === strpos( ini_get( 'disable_functions' ), 'set_time_limit' ) && ! ini_get( 'safe_mode' ) ) {
|
||||
set_time_limit( 0 );
|
||||
}
|
||||
@ob_flush();
|
||||
@flush();
|
||||
@ini_set( 'auto_detect_line_endings', '1' );
|
||||
|
|
|
@ -844,7 +844,9 @@ class WC_AJAX {
|
|||
die(-1);
|
||||
}
|
||||
|
||||
@set_time_limit(0);
|
||||
if ( function_exists( 'set_time_limit' ) && false === strpos( ini_get( 'disable_functions' ), 'set_time_limit' ) && ! ini_get( 'safe_mode' ) ) {
|
||||
set_time_limit( 0 );
|
||||
}
|
||||
|
||||
$post_id = intval( $_POST['post_id'] );
|
||||
|
||||
|
|
|
@ -338,11 +338,11 @@ class WC_Download_Handler {
|
|||
* Check and set certain server config variables to ensure downloads work as intended.
|
||||
*/
|
||||
private static function check_server_config() {
|
||||
if ( ! ini_get('safe_mode') ) {
|
||||
@set_time_limit(0);
|
||||
if ( function_exists( 'set_time_limit' ) && false === strpos( ini_get( 'disable_functions' ), 'set_time_limit' ) && ! ini_get( 'safe_mode' ) ) {
|
||||
set_time_limit( 0 );
|
||||
}
|
||||
if ( function_exists( 'get_magic_quotes_runtime' ) && get_magic_quotes_runtime() ) {
|
||||
@set_magic_quotes_runtime(0);
|
||||
if ( function_exists( 'get_magic_quotes_runtime' ) && get_magic_quotes_runtime() && version_compare( phpversion(), '5.4', '<' ) ) {
|
||||
set_magic_quotes_runtime( 0 );
|
||||
}
|
||||
if ( function_exists( 'apache_setenv' ) ) {
|
||||
@apache_setenv( 'no-gzip', 1 );
|
||||
|
|
Loading…
Reference in New Issue