Acked-by: Sairam Venugopal <[email protected]>




On 3/6/17, 8:22 AM, "[email protected] on behalf of Alin Serdean" 
<[email protected] on behalf of [email protected]> 
wrote:

>From: Alin Serdean <[email protected]>
>
>The variable `request_nlmsg` was used without being initialized.
>
>This patch assigns a value to it before being used.
>
>Found by inspection.
>
>Signed-off-by: Alin Gabriel Serdean <[email protected]>
>---
>v2: Change commit title
>---
> lib/netlink-socket.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
>diff --git a/lib/netlink-socket.c b/lib/netlink-socket.c
>index e45914c..7105b9b 100644
>--- a/lib/netlink-socket.c
>+++ b/lib/netlink-socket.c
>@@ -886,6 +886,8 @@ nl_sock_transact_multiple__(struct nl_sock *sock,
>         }
> 
>         if (reply_len != 0) {
>+            request_nlmsg = nl_msg_nlmsghdr(txn->request);
>+
>             if (reply_len < sizeof *reply_nlmsg) {
>                 nl_sock_record_errors__(transactions, n, 0);
>                 VLOG_DBG_RL(&rl, "insufficient length of reply %#"PRIu32
>@@ -894,7 +896,6 @@ nl_sock_transact_multiple__(struct nl_sock *sock,
>             }
> 
>             /* Validate the sequence number in the reply. */
>-            request_nlmsg = nl_msg_nlmsghdr(txn->request);
>             reply_nlmsg = (struct nlmsghdr *)reply_buf;
> 
>             if (request_nlmsg->nlmsg_seq != reply_nlmsg->nlmsg_seq) {
>-- 
>2.10.2.windows.1
>_______________________________________________
>dev mailing list
>[email protected]
>https://mail.openvswitch.org/mailman/listinfo/ovs-dev
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to