Service installation: bail out with a meaningful error message on unsupported platforms
Fixes #154
This commit is contained in:
parent
0fde986c63
commit
547e444afd
|
@ -44,6 +44,9 @@ func main() {
|
||||||
dlog.Noticef("dnscrypt-proxy %s", AppVersion)
|
dlog.Noticef("dnscrypt-proxy %s", AppVersion)
|
||||||
|
|
||||||
if len(*svcFlag) != 0 {
|
if len(*svcFlag) != 0 {
|
||||||
|
if svc == nil {
|
||||||
|
dlog.Fatal("Built-in service installation is not supported on this platform")
|
||||||
|
}
|
||||||
if err := service.Control(svc, *svcFlag); err != nil {
|
if err := service.Control(svc, *svcFlag); err != nil {
|
||||||
dlog.Fatal(err)
|
dlog.Fatal(err)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue