More tiny fixes/enhancements
This commit is contained in:
parent
970664429a
commit
8af3ab3fb6
4 changed files with 114 additions and 35 deletions
|
|
@ -42,12 +42,11 @@ func doUSBRootCheck() {
|
|||
ok, err := checkIfRoot()
|
||||
if err != nil {
|
||||
slog.Error("Failed to check whether the command is ran by root", "error", err.Error())
|
||||
os.Exit(1)
|
||||
return
|
||||
}
|
||||
|
||||
if !ok {
|
||||
slog.Error("USB passthrough on your OS requires this program to be ran as root")
|
||||
os.Exit(1)
|
||||
slog.Warn("USB passthrough on your OS usually requires this program to be ran as root")
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue