cmd/syncthing: Fail if -logfile and -no-restart passed together (fixes #3912)
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3915
This commit is contained in:
parent
bd1c29ee32
commit
4c8aa14e07
@ -320,6 +320,12 @@ func main() {
|
|||||||
os.Setenv("STGUIAPIKEY", options.guiAPIKey)
|
os.Setenv("STGUIAPIKEY", options.guiAPIKey)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Check for options which are not compatible with each other
|
||||||
|
// Have to check logfile before it's set to the default below - we only want to complain if they set -logfile explicitly, not if it's set to its default location
|
||||||
|
if options.noRestart && options.logFile != "" {
|
||||||
|
l.Fatalln("-logfile may not be used with -no-restart or STNORESTART")
|
||||||
|
}
|
||||||
|
|
||||||
if options.hideConsole {
|
if options.hideConsole {
|
||||||
osutil.HideConsole()
|
osutil.HideConsole()
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user