mirror of
https://github.com/ipmitool/ipmitool.git
synced 2025-05-10 18:47:22 +00:00
Olivier Fourdan's 8/16/08 patch to allow ipmitool sel delete to accept hex list entry numbers
This commit is contained in:
parent
e3abbf667a
commit
653c9b20d5
@ -31,6 +31,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
#include <stdlib.h> /* for strtoul, to parse hexadecimal values */
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#define __USE_XOPEN /* glibc2 needs this for strptime */
|
#define __USE_XOPEN /* glibc2 needs this for strptime */
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
@ -1987,7 +1988,7 @@ ipmi_sel_delete(struct ipmi_intf * intf, int argc, char ** argv)
|
|||||||
|
|
||||||
for (; argc != 0; argc--)
|
for (; argc != 0; argc--)
|
||||||
{
|
{
|
||||||
id = atoi(argv[argc-1]);
|
id = (uint16_t) strtoul(argv[argc-1], NULL, 0);
|
||||||
msg_data[2] = id & 0xff;
|
msg_data[2] = id & 0xff;
|
||||||
msg_data[3] = id >> 8;
|
msg_data[3] = id >> 8;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user