summaryrefslogtreecommitdiff
path: root/sql/multi_range_read.cc
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-04-06 15:51:08 +0200
committerSergei Golubchik <sergii@pisem.net>2013-04-06 15:51:08 +0200
commit5d9e50fc950502698d3beb95577bc5fe441b38b7 (patch)
tree6e17e30383acacdfc949a1ed54d4eb2b6d58a1e6 /sql/multi_range_read.cc
parent6770a9a836fcc8aa9f49f6b91ce237851638916b (diff)
downloadmariadb-git-5d9e50fc950502698d3beb95577bc5fe441b38b7.tar.gz
MDEV-4244 [PATCH] Buffer overruns and use-after-free errors
fixes for gcc 4.8 -fsanitize=address
Diffstat (limited to 'sql/multi_range_read.cc')
-rw-r--r--sql/multi_range_read.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/multi_range_read.cc b/sql/multi_range_read.cc
index e86c9ca251c..727ebc29032 100644
--- a/sql/multi_range_read.cc
+++ b/sql/multi_range_read.cc
@@ -1632,7 +1632,7 @@ int DsMrr_impl::dsmrr_explain_info(uint mrr_mode, char *str, size_t size)
uint used_str_len= strlen(used_str);
uint copy_len= min(used_str_len, size);
- memcpy(str, used_str, size);
+ memcpy(str, used_str, copy_len);
return copy_len;
}
return 0;