diff options
author | Jörg Frings-Fürst <debian@jff.email> | 2018-08-04 11:17:07 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff.email> | 2018-08-04 11:17:07 +0200 |
commit | 7af748e993f12dd5b62400723332a7c8b53dcd72 (patch) | |
tree | 277e7f1d30bd2ebccf90e8d13d6215b28ebacaf4 /util/ipmicmd.c | |
parent | 341aee5e3e3625173e4b684cc4166e60f6eb147f (diff) | |
parent | 999ee0be4949b34b9930e86a661e759f63b2072c (diff) |
Merge branch 'release/debian/3.1.2-1'debian/3.1.2-1
Diffstat (limited to 'util/ipmicmd.c')
-rw-r--r-- | util/ipmicmd.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/util/ipmicmd.c b/util/ipmicmd.c index b7c8a5f..f8ce1ba 100644 --- a/util/ipmicmd.c +++ b/util/ipmicmd.c @@ -90,6 +90,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #endif #include "ipmicmd.h" /* has NCMDS, ipmi_cmd_t */ +#include "ipmilan2.h" /*includes ipmilan.h also*/ ipmi_cmd_t ipmi_cmds[NCMDS] = { /*if add here, also change NCMDS in ipmicmd.h*/ {/*empty,temp*/ 0, BMC_SA, PUBLIC_BUS, NETFN_APP, BMC_LUN, 0, 20}, @@ -164,7 +165,6 @@ int ipmi_cmdraw_efi( uchar cmd, uchar netfn, uchar lun, uchar sa, uchar *presp, int *sresp, uchar *pcc, char fdebugcmd); #else -#include "ipmilan2.h" /*includes ipmilan.h also*/ #ifdef WIN32 extern int ipmi_cmdraw_ia( uchar cmd, uchar netfn, uchar lun, uchar sa, uchar bus, uchar *pdata, int sdata, @@ -1453,13 +1453,12 @@ char *get_nodename(void) return(gnode); } -extern int lasterr; /*defined in ipmilan.c */ -extern void show_LastError(char *tag, int err); - void show_outcome(char *prog, int ret) { + int err = 0; if (prog == NULL) prog = ""; - if (ret == -1 && lasterr != 0) show_LastError(prog,lasterr); + err = get_LastError(); + if (ret == -1 && err != 0) show_LastError(prog,err); printf("%s%c %s\n",prog,bcomma,decode_rv(ret)); } |