cmd/syncthing, lib/model: Handle rel/abs paths for config/protected paths (fixes #3183)
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3995
This commit is contained in:
@@ -344,7 +344,13 @@ func main() {
|
||||
|
||||
if options.confDir != "" {
|
||||
// Not set as default above because the string can be really long.
|
||||
baseDirs["config"] = options.confDir
|
||||
if !filepath.IsAbs(options.confDir) {
|
||||
path, err := filepath.Abs(options.confDir)
|
||||
if err != nil {
|
||||
l.Fatalln(err)
|
||||
}
|
||||
baseDirs["config"] = path
|
||||
}
|
||||
}
|
||||
|
||||
if err := expandLocations(); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user