[Commits] f856ad5: MDEV-11761: CLIENT_DEPRECATE_EOF : Client must identify a "stored procedure output resultset"

Oleksandr Byelkin sanja at mariadb.com
Wed Mar 15 14:44:14 EET 2017


revision-id: f856ad585666b9bc9bc63141e7e003c39c644889 (mariadb-10.2.4-61-gf856ad5)
parent(s): b5285bd7e201ce522b42d18664f171a4e47f5ecd
committer: Oleksandr Byelkin
timestamp: 2017-03-15 13:44:14 +0100
message:

MDEV-11761: CLIENT_DEPRECATE_EOF  : Client must identify a "stored procedure output resultset"

fix proposed by Diego

---
 sql/protocol.cc | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/sql/protocol.cc b/sql/protocol.cc
index f8b68c0..b9d9f28 100644
--- a/sql/protocol.cc
+++ b/sql/protocol.cc
@@ -1617,16 +1617,14 @@ bool Protocol_binary::send_out_parameters(List<Item_param> *sp_params)
   if (write())
     return TRUE;
 
-  /* Restore THD::server_status. */
-  thd->server_status&= ~SERVER_PS_OUT_PARAMS;
-
   ret= net_send_eof(thd, thd->server_status, 0);
 
   /*
-    Reset SERVER_MORE_RESULTS_EXISTS bit, because this is the last packet
-    for sure.
+    Reset server_status:
+    - SERVER_MORE_RESULTS_EXISTS bit, because this is the last packet for sure.
+    - Restore SERVER_PS_OUT_PARAMS status.
   */
-  thd->server_status&= ~SERVER_MORE_RESULTS_EXISTS;
+  thd->server_status&= ~(SERVER_PS_OUT_PARAMS | SERVER_MORE_RESULTS_EXISTS);
 
   return ret ? FALSE : TRUE;
 }


More information about the commits mailing list