diff --git a/server/modules/routing/readwritesplit/rwsplit_session_cmd.cc b/server/modules/routing/readwritesplit/rwsplit_session_cmd.cc index 63d910c04..76119b975 100644 --- a/server/modules/routing/readwritesplit/rwsplit_session_cmd.cc +++ b/server/modules/routing/readwritesplit/rwsplit_session_cmd.cc @@ -40,7 +40,7 @@ void process_sescmd_response(RWSplitSession* rses, SRWBackend& backend, uint64_t id = backend->complete_session_command(); MXS_PS_RESPONSE resp = {}; - if (command == MXS_COM_STMT_PREPARE) + if (command == MXS_COM_STMT_PREPARE && cmd != MYSQL_REPLY_ERR) { // This should never fail or the backend protocol is broken ss_debug(bool b = )mxs_mysql_extract_ps_response(*ppPacket, &resp);