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 | 42d39e6e0828035af77d091db089b0104c4ac6d4 (patch) | |
tree | 9488f4d1905fb8807377eca546652631ca21f4a2 /sql/sql_cache.cc | |
parent | d6d11c8eb1dc5f6ea413d61238c3e48ec1e043b7 (diff) | |
parent | 8444b6a1149aad457f8d584e0d410c3be9cd4336 (diff) | |
download | mariadb-git-42d39e6e0828035af77d091db089b0104c4ac6d4.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, |