msg_channel: Fix a 100% CPU loop
commit7e38fcb93e699cd55f000ae019671283c3464723
authorVolker Lendecke <vl@samba.org>
Tue, 10 Jun 2014 14:21:07 +0000 (10 14:21 +0000)
committerKarolin Seeger <kseeger@samba.org>
Tue, 15 Jul 2014 10:46:11 +0000 (15 12:46 +0200)
tree5bf7b53bf3fd82f568fe72607029adbf37f6e5f7
parent406e412ab681ba08ffdc182e999fb73a63abbbde
msg_channel: Fix a 100% CPU loop

In a ctdb setup, msg_read_got_ctdb did not set channel->pending_req to
NULL. In smbXsrv_session_close_loop in any error condition this leads to
a 100% loop. smbXsrv_session_close_loop continously retries, but because
close_channel->pending_req is != NULL, msg_read_send will always return
EBUSY, making smbXsrv_session_close_loop retry infinitely.

This patch makes sure that msg_read_got_ctdb correctly NULLs out pending_req.

msg_channel.c does not exist in master anymore, so this patch is 4.1 only.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10663
100% smbd cpu loop in ctdb setups
source3/lib/msg_channel.c