Don't panic if there's no command line arguments
This commit is contained in:
parent
b6d91a2bda
commit
6514c3ab16
1 changed files with 1 additions and 1 deletions
|
|
@ -50,7 +50,7 @@ fn main() {
|
|||
let mut term = Term::new();
|
||||
let cmd = os::args();
|
||||
|
||||
if cmd.len() < 1 {
|
||||
if cmd.len() <= 1 {
|
||||
help::usage()
|
||||
} else {
|
||||
match subcommand::parse_name(&cmd[1][]) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue