提交 0b33a916 编写于 作者: L Lars Ellenberg 提交者: Philipp Reisner

add missing state change on corrupt packet header in drbd_recv_header

Otherwise the 'state fixup' in the receiver will change to Unconnected,
but the receiver will terminate itself, and any attempt at 'down'ing
that drbd later will block forever.

see also Bugz. #259
Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com>
上级 6c6c7951
......@@ -3499,8 +3499,10 @@ static void drbdd(struct drbd_conf *mdev)
while (get_t_state(&mdev->receiver) == Running) {
drbd_thread_current_set_cpu(mdev);
if (!drbd_recv_header(mdev, header))
if (!drbd_recv_header(mdev, header)) {
drbd_force_state(mdev, NS(conn, C_PROTOCOL_ERROR));
break;
}
if (header->command < P_MAX_CMD)
handler = drbd_cmd_handler[header->command];
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册