From 287b313e2641f6ffed39b5cc4548a3f05fd33b96 Mon Sep 17 00:00:00 2001 From: Zdenek Styblik Date: Tue, 9 Jul 2013 11:10:03 +0000 Subject: [PATCH] ID: 113 - delloem exec file won't handle more than one command Commit fixes issue with 'delloem' subcommands being executed via 'exec'. State of variable 'current_arg' is kept between calls which leads to incorrect argv parsing. Set variable 'current_arg' every time ipmi_delloem_main() is called. --- ipmitool/lib/ipmi_delloem.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ipmitool/lib/ipmi_delloem.c b/ipmitool/lib/ipmi_delloem.c index 13e9811..b4e541a 100644 --- a/ipmitool/lib/ipmi_delloem.c +++ b/ipmitool/lib/ipmi_delloem.c @@ -257,6 +257,7 @@ int ipmi_delloem_main(struct ipmi_intf * intf, int argc, char ** argv) { int rc = 0; + current_arg = 0; if (argc == 0 || strncmp(argv[0], "help\0", 5) == 0) { usage(); return 0;