Skip to content

Commit

Permalink
Merge pull request #115 from manugupt1/minor-nits
Browse files Browse the repository at this point in the history
Update doc to use fs.ErrNotExist
  • Loading branch information
thaJeztah committed May 26, 2022
2 parents 28ef7ed + 4734a9e commit ad57f78
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion mountinfo/mounted_linux.go
Expand Up @@ -15,7 +15,7 @@ import (
//
// If a non-existent path is specified, an appropriate error is returned.
// In case the caller is not interested in this particular error, it should
// be handled separately using e.g. errors.Is(err, os.ErrNotExist).
// be handled separately using e.g. errors.Is(err, fs.ErrNotExist).
//
// This function is only available on Linux. When available (since kernel
// v5.6), openat2(2) syscall is used to reliably detect all mounts. Otherwise,
Expand Down
2 changes: 1 addition & 1 deletion mountinfo/mountinfo.go
Expand Up @@ -15,7 +15,7 @@ func GetMounts(f FilterFunc) ([]*Info, error) {
//
// If a non-existent path is specified, an appropriate error is returned.
// In case the caller is not interested in this particular error, it should
// be handled separately using e.g. errors.Is(err, os.ErrNotExist).
// be handled separately using e.g. errors.Is(err, fs.ErrNotExist).
func Mounted(path string) (bool, error) {
// root is always mounted
if path == string(os.PathSeparator) {
Expand Down

0 comments on commit ad57f78

Please sign in to comment.