mirror of
https://github.com/scr34m/php-malware-scanner.git
synced 2026-06-16 12:30:35 +00:00
Merge pull request #33 from marek-knappe/fix-cli-relative-directory
Add real path conversion for cli scan.php to have relative path.
This commit is contained in:
3
scan.php
3
scan.php
@@ -64,10 +64,11 @@ class MalwareScanner
|
||||
if ($cli === true) {
|
||||
//Read Run Options
|
||||
$this->parseArgs();
|
||||
$this->dir = realpath($this->dir);
|
||||
|
||||
//Make sure a directory was specified.
|
||||
if ($this->dir === '') {
|
||||
$this->error('No directory specified');
|
||||
$this->error('No directory specified or directory doesn\'t exist');
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user