Skip to content

Commit

Permalink
Added conditional to prevent redeclaration of class
Browse files Browse the repository at this point in the history
Some users have reported that using APC and/or FastCGI causes an
internal server error with the declaration of the class used to manage
the code for the malware scanner settings; this is because APC has a bug
that duplicates the autoloaders thinking that a class was defined twice,
the only apparent solution is to set these settings:

apc.include_once_override = 0
apc.canonicalize = 0
apc.stat = 0
  • Loading branch information
cixtor committed Jul 9, 2016
1 parent 24d9a07 commit f21d2e9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sucuri.php
Expand Up @@ -13555,6 +13555,7 @@ function sucuriscan_settings_corefiles_cache($nonce)
return SucuriScanTemplate::getSection('settings-corefiles-cache', $params);
}

if (!class_exists('SucuriScanSiteCheck')) {
class SucuriScanSiteCheck extends SucuriScanSettings
{
public static function isEnabled()
Expand Down Expand Up @@ -13647,6 +13648,7 @@ public static function timeoutPage($nonce)
return SucuriScanTemplate::getSection('settings-sitecheck-timeout', $params);
}
}
}

/**
* Read and parse the content of the SiteCheck settings template.
Expand Down

0 comments on commit f21d2e9

Please sign in to comment.