From f87420b587bdda3631bb543256e78a65eb5fab85 Mon Sep 17 00:00:00 2001 From: Duncan Laurie Date: Thu, 2 Jun 2005 22:01:36 +0000 Subject: [PATCH] don't return error when user not supported --- ipmitool/lib/ipmi_user.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ipmitool/lib/ipmi_user.c b/ipmitool/lib/ipmi_user.c index 5739d72..d34acd7 100644 --- a/ipmitool/lib/ipmi_user.c +++ b/ipmitool/lib/ipmi_user.c @@ -142,6 +142,8 @@ ipmi_get_user_name( struct ipmi_rq req; uint8_t msg_data[1]; + memset(user_name, 0, 17); + memset(&req, 0, sizeof(req)); req.msg.netfn = IPMI_NETFN_APP; /* 0x06 */ req.msg.cmd = IPMI_GET_USER_NAME; /* 0x45 */ @@ -158,6 +160,8 @@ ipmi_get_user_name( return -1; } if (rsp->ccode > 0) { + if (rsp->ccode == 0xcc) + return 0; lprintf(LOG_ERR, "Get User Name command failed (user %d): %s", user_id, val2str(rsp->ccode, completion_code_vals)); return -1;