mirror of
https://github.com/ipmitool/ipmitool.git
synced 2025-05-10 18:47:22 +00:00
Replace deprecated bzero() with memset()
Commit replaces deprecated bzero() with memset().
This commit is contained in:
parent
140add9d77
commit
0a1f5c03e5
@ -68,8 +68,7 @@ ipmi_1_5_authtypes(uint8_t n)
|
|||||||
uint32_t i;
|
uint32_t i;
|
||||||
static char supportedTypes[128];
|
static char supportedTypes[128];
|
||||||
|
|
||||||
bzero(supportedTypes, 128);
|
memset(supportedTypes, 0, sizeof(supportedTypes));
|
||||||
|
|
||||||
for (i = 0; ipmi_authtype_vals[i].val != 0; i++) {
|
for (i = 0; ipmi_authtype_vals[i].val != 0; i++) {
|
||||||
if (n & ipmi_authtype_vals[i].val) {
|
if (n & ipmi_authtype_vals[i].val) {
|
||||||
strcat(supportedTypes, ipmi_authtype_vals[i].str);
|
strcat(supportedTypes, ipmi_authtype_vals[i].str);
|
||||||
|
@ -1198,8 +1198,7 @@ get_cmdline_cipher_suite_priv_data(char * arg, uint8_t * buf)
|
|||||||
* data 3 - maximum priv level for third (LSN) and fourth (MSN) ciphers
|
* data 3 - maximum priv level for third (LSN) and fourth (MSN) ciphers
|
||||||
* data 9 - maximum priv level for 15th (LSN) cipher.
|
* data 9 - maximum priv level for 15th (LSN) cipher.
|
||||||
*/
|
*/
|
||||||
bzero(buf, 9);
|
memset(buf, 0, 9);
|
||||||
|
|
||||||
for (i = 0; i < 15; ++i)
|
for (i = 0; i < 15; ++i)
|
||||||
{
|
{
|
||||||
unsigned char priv_level = IPMI_SESSION_PRIV_ADMIN;
|
unsigned char priv_level = IPMI_SESSION_PRIV_ADMIN;
|
||||||
|
@ -1300,7 +1300,7 @@ ipmi_sol_deactivate(struct ipmi_intf * intf, int instance)
|
|||||||
req.msg.data_len = 6;
|
req.msg.data_len = 6;
|
||||||
req.msg.data = data;
|
req.msg.data = data;
|
||||||
|
|
||||||
bzero(data, sizeof(data));
|
memset(data, 0, sizeof(data));
|
||||||
data[0] = IPMI_PAYLOAD_TYPE_SOL; /* payload type */
|
data[0] = IPMI_PAYLOAD_TYPE_SOL; /* payload type */
|
||||||
data[1] = instance; /* payload instance. */
|
data[1] = instance; /* payload instance. */
|
||||||
|
|
||||||
|
@ -2574,7 +2574,7 @@ ack_sol_packet(
|
|||||||
{
|
{
|
||||||
struct ipmi_v2_payload ack;
|
struct ipmi_v2_payload ack;
|
||||||
|
|
||||||
bzero(&ack, sizeof(struct ipmi_v2_payload));
|
memset(ack, 0, sizeof(struct ipmi_v2_payload));
|
||||||
|
|
||||||
ack.payload_type = IPMI_PAYLOAD_TYPE_SOL;
|
ack.payload_type = IPMI_PAYLOAD_TYPE_SOL;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user