Replace deprecated bzero() with memset()

Commit replaces deprecated bzero() with memset().
This commit is contained in:
Zdenek Styblik 2014-12-23 05:46:28 +01:00
parent 140add9d77
commit 0a1f5c03e5
4 changed files with 4 additions and 6 deletions

View File

@ -68,8 +68,7 @@ ipmi_1_5_authtypes(uint8_t n)
uint32_t i;
static char supportedTypes[128];
bzero(supportedTypes, 128);
memset(supportedTypes, 0, sizeof(supportedTypes));
for (i = 0; ipmi_authtype_vals[i].val != 0; i++) {
if (n & ipmi_authtype_vals[i].val) {
strcat(supportedTypes, ipmi_authtype_vals[i].str);

View File

@ -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 9 - maximum priv level for 15th (LSN) cipher.
*/
bzero(buf, 9);
memset(buf, 0, 9);
for (i = 0; i < 15; ++i)
{
unsigned char priv_level = IPMI_SESSION_PRIV_ADMIN;

View File

@ -1300,7 +1300,7 @@ ipmi_sol_deactivate(struct ipmi_intf * intf, int instance)
req.msg.data_len = 6;
req.msg.data = data;
bzero(data, sizeof(data));
memset(data, 0, sizeof(data));
data[0] = IPMI_PAYLOAD_TYPE_SOL; /* payload type */
data[1] = instance; /* payload instance. */

View File

@ -2574,7 +2574,7 @@ ack_sol_packet(
{
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;