`sky` panics when no CLI args given
elimisteve opened this issue · 1 comments
elimisteve commented
args
, as defined by
flagsetArgs, additionalArgs := skynet.SplitFlagsetFromArgs(flagset, os.Args[1:])
c, args := skynet.GetClientConfigFromFlags(additionalArgs)
...
is assumed to be non-empty, as the expression args[0]
is what triggers the panic, but if no command line arguments are given, it is empty.
$ sky
doozer: 2013/01/08 01:34:48 trace: skynet.DoozerConnected: Connected to doozer at 127.0.0.1:8046
panic: runtime error: index out of range
goroutine 1 [running]:
main.main()
/home/steve/gocode/src/github.com/skynetservices/skynet/cmd/sky/sky.go:49 +0x345
...
elimisteve commented
Already merged