Merge pull request #728 from fancybits/android-filesystems
ignore /proc/filesystems errors on android
This commit is contained in:
commit
0bb41276be
|
@ -10,6 +10,7 @@ import (
|
|||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
|
@ -244,7 +245,7 @@ func PartitionsWithContext(ctx context.Context, all bool) ([]PartitionStat, erro
|
|||
}
|
||||
|
||||
fs, err := getFileSystems()
|
||||
if err != nil {
|
||||
if err != nil && all {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue