diff options
author | Tatjana Azundris Nuernberg <tatjana.nuernberg@oracle.com> | 2011-10-19 03:42:09 +0100 |
---|---|---|
committer | Tatjana Azundris Nuernberg <tatjana.nuernberg@oracle.com> | 2011-10-19 03:42:09 +0100 |
commit | ec56c16c4b0bab67d7fdc77f7fc7532b83273499 (patch) | |
tree | 9488f4d1905fb8807377eca546652631ca21f4a2 /sql/sql_cache.cc | |
parent | add59cfbaf7865ff8be3038197320e4eabd5767f (diff) | |
parent | 7d882c19ecad83af921dd7bd9d77f088da594ac0 (diff) | |
download | mariadb-git-ec56c16c4b0bab67d7fdc77f7fc7532b83273499.tar.gz |
Bug12589870 post merge fixes - manual merge
Diffstat (limited to 'sql/sql_cache.cc')
-rw-r--r-- | sql/sql_cache.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sql/sql_cache.cc b/sql/sql_cache.cc index e8bc6160cfd..56ce6607c85 100644 --- a/sql/sql_cache.cc +++ b/sql/sql_cache.cc @@ -1515,8 +1515,9 @@ Query_cache::send_result_to_client(THD *thd, char *sql, uint query_length) sure the new current database has a name with the same length as the previous one. */ - size_t *db_len= (size_t *) (sql + query_length + 1); - if (thd->db_length != *db_len) + size_t db_len; + memcpy((char *) &db_len, (sql + query_length + 1), sizeof(size_t)); + if (thd->db_length != db_len) { /* We should probably reallocate the buffer in this case, |