diff options
author | kostja@bodhi.(none) <> | 2007-12-12 18:21:01 +0300 |
---|---|---|
committer | kostja@bodhi.(none) <> | 2007-12-12 18:21:01 +0300 |
commit | ebb9c5d9838f333a73fb197d2bb59ff4ccab6fb9 (patch) | |
tree | 6d167294e7739c87e6a12c0d29fa35aa57b0ae36 /include/mysql_com.h | |
parent | aa5786eb0f3fbde0a0c8278de22897a8f0fec0e8 (diff) | |
download | mariadb-git-ebb9c5d9838f333a73fb197d2bb59ff4ccab6fb9.tar.gz |
Bug#12713 "Error in a stored function called from a SELECT doesn't
cause ROLLBACK of statement", part 1. Review fixes.
Do not send OK/EOF packets to the client until we reached the end of
the current statement.
This is a consolidation, to keep the functionality that is shared by all
SQL statements in one place in the server.
Currently this functionality includes:
- close_thread_tables()
- log_slow_statement().
After this patch and the subsequent patch for Bug#12713, it shall also include:
- ha_autocommit_or_rollback()
- net_end_statement()
- query_cache_end_of_result().
In future it may also include:
- mysql_reset_thd_for_next_command().
Diffstat (limited to 'include/mysql_com.h')
-rw-r--r-- | include/mysql_com.h | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/include/mysql_com.h b/include/mysql_com.h index 4ae7f66060f..b94a783e839 100644 --- a/include/mysql_com.h +++ b/include/mysql_com.h @@ -203,14 +203,10 @@ typedef struct st_net { unsigned int *return_status; unsigned char reading_or_writing; char save_char; - my_bool no_send_ok; /* For SPs and other things that do multiple stmts */ + my_bool unused0; /* Please remove with the next incompatible ABI change. */ my_bool unused; /* Please remove with the next incompatible ABI change */ my_bool compress; - /* - Set if OK packet is already sent, and we do not need to send error - messages - */ - my_bool no_send_error; + my_bool unused1; /* Please remove with the next incompatible ABI change. */ /* Pointer to query object in query cache, do not equal NULL (0) for queries in cache that have not stored its results yet @@ -221,11 +217,14 @@ typedef struct st_net { functions and methods to maintain proper locking. */ unsigned char *query_cache_query; - unsigned int last_errno; - unsigned char error; - my_bool report_error; /* We should report error (we have unreported error) */ + unsigned int client_last_errno; + unsigned char error; + my_bool unused2; /* Please remove with the next incompatible ABI change. */ my_bool return_errno; - char last_error[MYSQL_ERRMSG_SIZE], sqlstate[SQLSTATE_LENGTH+1]; + /** Client library error message buffer. Actually belongs to struct MYSQL. */ + char client_last_error[MYSQL_ERRMSG_SIZE]; + /** Client library sqlstate buffer. Set along with the error message. */ + char sqlstate[SQLSTATE_LENGTH+1]; void *extension; } NET; |