Skip to content

Commit

Permalink
Wasn't checking bounds on arguments in balance. Issue #566
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulSnow committed Jul 24, 2015
1 parent b03ab99 commit 5894f22
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion balance.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ func balance(args []string) error {
os.Args = args
flag.Parse()
args = flag.Args()
if len(args) < 1 {
if len(args) < 2 {
fmt.Println("Too few arguments")
man("balance")
return fmt.Errorf("Too Few Arguments")
}
Expand Down

0 comments on commit 5894f22

Please sign in to comment.