From 74135776c744ef10da22c53cf57107b035b686a2 Mon Sep 17 00:00:00 2001 From: Anoke Date: Wed, 8 May 2024 01:08:50 +0300 Subject: [PATCH] [#1067] adm: Fix panic on negative value Signed-off-by: Anoke --- cmd/frostfs-adm/internal/modules/morph/policy/policy.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/frostfs-adm/internal/modules/morph/policy/policy.go b/cmd/frostfs-adm/internal/modules/morph/policy/policy.go index a11ca2704..5ab05e429 100644 --- a/cmd/frostfs-adm/internal/modules/morph/policy/policy.go +++ b/cmd/frostfs-adm/internal/modules/morph/policy/policy.go @@ -48,7 +48,7 @@ func SetPolicyCmd(cmd *cobra.Command, args []string) error { value, err := strconv.ParseUint(v, 10, 32) if err != nil { - return fmt.Errorf("can't parse parameter value '%s': %w", args[1], err) + return fmt.Errorf("can't parse parameter value '%s': %w", args[i], err) } emit.AppCall(bw.BinWriter, policy.Hash, "set"+k, callflag.All, int64(value))