diff options
author | unknown <guilhem@mysql.com> | 2004-09-07 14:57:54 +0200 |
---|---|---|
committer | unknown <guilhem@mysql.com> | 2004-09-07 14:57:54 +0200 |
commit | 32db5b4c5eb4dddf6401f3a926645a1972fa5369 (patch) | |
tree | 790661e2d03e6fbacccd70957d8f9df8397563ee /sql/sql_db.cc | |
parent | e4ff34388a5aa3fa297085d1a20fdd4d31a0a174 (diff) | |
download | mariadb-git-32db5b4c5eb4dddf6401f3a926645a1972fa5369.tar.gz |
when we update thd->db in replication, it's safer to update thd->db_length too.
This does not fix any known bug, but is still a good idea.
sql/log_event.cc:
when we update thd->db in replication, it's safer to update thd->db_length too.
sql/slave.cc:
when we update thd->db in replication, it's safer to update thd->db_length too.
sql/sql_db.cc:
comment
Diffstat (limited to 'sql/sql_db.cc')
-rw-r--r-- | sql/sql_db.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sql/sql_db.cc b/sql/sql_db.cc index 3d877403813..c8874701aa1 100644 --- a/sql/sql_db.cc +++ b/sql/sql_db.cc @@ -385,6 +385,15 @@ err: } +/* + Changes the current database. + + NOTES + Do as little as possible in this function, as it is not called for the + replication slave SQL thread (for that thread, setting of thd->db is done + in ::exec_event() methods of log_event.cc). +*/ + bool mysql_change_db(THD *thd,const char *name) { int length, db_length; |