mirror of
https://github.com/anchore/syft.git
synced 2025-11-17 16:33:21 +01:00
fix: use filepath instead of path for file source exclusions (#2411)
Signed-off-by: Wayne Starr <me@racer159.com>
This commit is contained in:
parent
67dbd1fe4c
commit
8bca0ac39e
@ -189,7 +189,7 @@ func (s FileSource) FileResolver(_ Scope) (file.Resolver, error) {
|
||||
return fs.SkipDir
|
||||
}
|
||||
|
||||
if path.Base(p) != path.Base(s.config.Path) {
|
||||
if filepath.Base(p) != filepath.Base(s.config.Path) {
|
||||
// we're in the root directory, but this is not the file we want to scan...
|
||||
// we should selectively skip this file (not the directory we're in).
|
||||
return fileresolver.ErrSkipPath
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user