lib/osutil: Return "/" as filesystem root on non-windows (fixes #3321)
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3332
This commit is contained in:
committed by
Jakob Borg
parent
379e2119a8
commit
502bee9a09
@@ -8,6 +8,6 @@
|
||||
|
||||
package osutil
|
||||
|
||||
func GetDriveLetters() ([]string, error) {
|
||||
return nil, nil
|
||||
func GetFilesystemRoots() ([]string, error) {
|
||||
return []string{"/"}, nil
|
||||
}
|
||||
@@ -15,7 +15,7 @@ import (
|
||||
"unsafe"
|
||||
)
|
||||
|
||||
func GetDriveLetters() ([]string, error) {
|
||||
func GetFilesystemRoots() ([]string, error) {
|
||||
kernel32, err := syscall.LoadDLL("kernel32.dll")
|
||||
if err != nil {
|
||||
return nil, err
|
||||
Reference in New Issue
Block a user