diff --git a/dirname/dirname.go b/dirname/dirname.go index 7ea5e94..2b9fd6d 100644 --- a/dirname/dirname.go +++ b/dirname/dirname.go @@ -8,12 +8,12 @@ import ( func usage() { fmt.Printf("usage: %v path\n", os.Args[0]) + os.Exit(1) } func main() { if len(os.Args) != 2 { usage() - os.Exit(1) } fmt.Println(path.Dir(os.Args[1]))