Skip to content

Commit

Permalink
🧹 do not error on filepath.SkipDir when reading linux bios
Browse files Browse the repository at this point in the history
Migrate #1461

Fixes #1474

Signed-off-by: Dominik Richter <[email protected]>
  • Loading branch information
arlimus committed Sep 20, 2023
1 parent c2a13a0 commit 29397e6
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion providers/os/resources/smbios/linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,5 +98,10 @@ func (s *LinuxSmbiosManager) Info() (*SmBiosInfo, error) {
return nil
})

return &smInfo, wErr
// If the error is SkipDir we can safely ignore it
if wErr != nil && wErr != filepath.SkipDir {
return nil, wErr
}

return &smInfo, nil
}

0 comments on commit 29397e6

Please sign in to comment.