Commit 0d98329c authored by Richard Clarkson's avatar Richard Clarkson
Browse files

Limit blacklist to php files

During performance optimization I have discovered that the installer scans all files for the blacklisted words. This greatly impacts speed on lower end devices such as the raspberry pie. This commit limits it to PHP files which seems to achieve the desired effect. 

I have used the --include option to achieve this, see

This contribution is MIT licensed
parent 05a069c1
......@@ -568,7 +568,7 @@ class OC_Installer{
// iterate the bad patterns
foreach($blacklist as $bl) {
$cmd = 'grep -ri '.escapeshellarg($bl).' '.$folder.'';
$cmd = 'grep --include \\*.php -ri '.escapeshellarg($bl).' '.$folder.'';
$result = exec($cmd);
// bad pattern found
if($result<>'') {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment