fixing get_gateway malloc error issue #21

This commit is contained in:
Zakir Durumeric 2013-08-19 11:34:16 -04:00
parent 314fb7b1de
commit 2a2ce7a2d0
1 changed files with 1 additions and 1 deletions

View File

@ -72,7 +72,7 @@ int send_nl_req(uint16_t msg_type, uint32_t seq,
return -1;
}
memset(nlmsg, 0, sizeof(nlmsg));
memset(nlmsg, 0, sizeof(struct nlmsghdr));
memcpy(NLMSG_DATA(nlmsg), payload, payload_len);
nlmsg->nlmsg_type = msg_type;
nlmsg->nlmsg_len = NLMSG_LENGTH(payload_len);