Erik's suggest seems better.

Regards,
Ying

-----Original Message-----
From: Erik Hugne [mailto:[email protected]] 
Sent: Tuesday, June 14, 2016 2:24 AM
To: Jon Maloy
Cc: [email protected]; 
[email protected]; Xue, Ying; [email protected]; 
[email protected]
Subject: Re: [tipc-discussion] [PATCH net v3 1/1] tipc: fix socket timer 
deadlock

On Mon, Jun 13, 2016 at 01:51:15PM -0400, Jon Maloy wrote:
> --- a/net/tipc/socket.c
> +++ b/net/tipc/socket.c
> @@ -1830,6 +1834,14 @@ void tipc_sk_rcv(struct net *net, struct sk_buff_head 
> *inputq)
>                               tipc_sk_enqueue(inputq, sk, dport);
>                               spin_unlock_bh(&sk->sk_lock.slock);
>                       }
> +                     /* Send pending response/rejected messages, if any */
> +                     while (!skb_queue_empty(&sk->sk_write_queue)) {
> +                             skb = skb_dequeue(&sk->sk_write_queue);
> +                             if (!skb)
> +                                     break;
> +                             dnode = msg_destnode(buf_msg(skb));
> +                             tipc_node_xmit_skb(net, skb, dnode, dport);
> +                     }

Might i suggest this instead?
        while ((skb = skb_dequeue(&sk->sk_write_queue))) {
                dnode = msg_destnode(buf_msg(skb));
                tipc_node_xmit_skb(net, skb, dnode, dport);
        }

//E

------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports. http://pubads.g.doubleclick.net/gampad/clk?id=1444514421&iu=/41014381
_______________________________________________
tipc-discussion mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tipc-discussion

Reply via email to