From 1098184c47674481a397af86054fb3fb15a89b77 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Wed, 12 Jun 2013 22:12:09 +0200 Subject: MDEV-4604 Wrong server status when sending out parameters reset SERVER_MORE_RESULTS_EXISTS *after* sending the OUT packet to the client. the next packet will be the last one. patch by Georg Richter. --- sql/protocol.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sql/protocol.cc') diff --git a/sql/protocol.cc b/sql/protocol.cc index 3af7dc88b88..2f19843e3e2 100644 --- a/sql/protocol.cc +++ b/sql/protocol.cc @@ -1546,14 +1546,14 @@ bool Protocol_binary::send_out_parameters(List *sp_params) /* Restore THD::server_status. */ thd->server_status&= ~SERVER_PS_OUT_PARAMS; + /* Send EOF-packet. */ + net_send_eof(thd, thd->server_status, 0); + /* Reset SERVER_MORE_RESULTS_EXISTS bit, because this is the last packet for sure. */ thd->server_status&= ~SERVER_MORE_RESULTS_EXISTS; - /* Send EOF-packet. */ - net_send_eof(thd, thd->server_status, 0); - return FALSE; } -- cgit v1.2.1