summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-03-01 23:13:45 +0200
committerPaul Buetow <paul@buetow.org>2026-03-01 23:13:45 +0200
commit5ed684ffe3be5397c486ec0859145031a960c7dc (patch)
treecd3c4ca9f6c9b66835276eb28bea2a217297d110 /cmd
parentf16162fc01429c1759adb4a63ba9a31f229e1603 (diff)
flags: return parse errors instead of exiting (task 321)
Diffstat (limited to 'cmd')
-rw-r--r--cmd/ior/main.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/cmd/ior/main.go b/cmd/ior/main.go
index 595f8f6..2b852f0 100644
--- a/cmd/ior/main.go
+++ b/cmd/ior/main.go
@@ -18,7 +18,10 @@ func main() {
}
// Parse command-line flags
- flags.Parse()
+ if err := flags.Parse(); err != nil {
+ fmt.Printf("Failed to parse flags: %v\n", err)
+ os.Exit(2)
+ }
// Run the internal logic of the application
if err := internal.Run(); err != nil {