From 326a8c8984ba70f1dae58cb08d75312df97e2887 Mon Sep 17 00:00:00 2001 From: Banana-J Date: Mon, 29 Jan 2024 11:31:21 +1100 Subject: [PATCH] fix: Fix Potential Index Out of Bound (#409) --- cmd/swarm/hash.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/swarm/hash.go b/cmd/swarm/hash.go index fca405ea2651..1a2583ac8b8c 100644 --- a/cmd/swarm/hash.go +++ b/cmd/swarm/hash.go @@ -33,7 +33,7 @@ func hash(ctx *cli.Context) { } f, err := os.Open(args[0]) if err != nil { - utils.Fatalf("Error opening file " + args[1]) + utils.Fatalf("Error opening file " + args[0]) } defer f.Close()