diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2020-09-03 09:10:03 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2020-09-03 09:10:03 +0300 |
commit | 2a93e632b1676b6df3dde150888d6428a57f8399 (patch) | |
tree | f9eac87b11d4e4666e50ac865aa82cac6f50a852 /sql/debug_sync.cc | |
parent | 9aea50616c2d8e067e5ce3efb1152e81877bf931 (diff) | |
parent | 94a520ddbe39ae97de1135d98699cf2674e6b77e (diff) | |
download | mariadb-git-2a93e632b1676b6df3dde150888d6428a57f8399.tar.gz |
Merge 10.1 into 10.2
Diffstat (limited to 'sql/debug_sync.cc')
-rw-r--r-- | sql/debug_sync.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/debug_sync.cc b/sql/debug_sync.cc index e50ab0891ed..b1846bc48d5 100644 --- a/sql/debug_sync.cc +++ b/sql/debug_sync.cc @@ -1,4 +1,5 @@ /* Copyright (c) 2009, 2013, Oracle and/or its affiliates. + Copyright (c) 2013, 2020, MariaDB This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -319,7 +320,8 @@ static char *debug_sync_bmove_len(char *to, char *to_end, DBUG_ASSERT(to_end); DBUG_ASSERT(!length || from); set_if_smaller(length, (size_t) (to_end - to)); - memcpy(to, from, length); + if (length) + memcpy(to, from, length); return (to + length); } |