diff options
author | Dmitry Shulga <dmitry.shulga@mariadb.com> | 2020-11-04 13:33:30 +0700 |
---|---|---|
committer | Dmitry Shulga <dmitry.shulga@mariadb.com> | 2020-11-04 13:33:30 +0700 |
commit | c5ff2284cce488037579b162e00343ebcbff783e (patch) | |
tree | 8228b4902384eca44440c93c50621d7c436cb0d8 | |
parent | 1418439d3823fe059b41092af72ab32d5e7cd7ab (diff) | |
download | mariadb-git-bb-10.5-MDEV-24116.tar.gz |
MDEV-24116: Build failure on MacOS on compiling the file lock/lock0lock.ccbb-10.5-MDEV-24116
Compiling MariaDB server on MacOS 10.15 results in the following error:
mariadb/server-10.5/storage/innobase/lock/lock0lock.cc:5035:23: error: loop variable
'page_id' of type 'const page_id_t' creates a copy from type 'const page_id_t'
[-Werror,-Wrange-loop-analysis]
for (const page_id_t page_id : pages) {
^
mariadb/server-10.5/storage/innobase/lock/lock0lock.cc:5035:7: note: use reference
type 'const page_id_t &' to prevent copying
for (const page_id_t page_id : pages) {
^~~~~~~~~~~~~~~~~~~~~~~~~
&
To fix this complation error the 'const' modified has been removed from
declaration of the loop variable page_id.
-rw-r--r-- | storage/innobase/lock/lock0lock.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/storage/innobase/lock/lock0lock.cc b/storage/innobase/lock/lock0lock.cc index 42ab5d061af..56c3aeecc73 100644 --- a/storage/innobase/lock/lock0lock.cc +++ b/storage/innobase/lock/lock0lock.cc @@ -5032,7 +5032,7 @@ lock_validate() lock_mutex_exit(); - for (const page_id_t page_id : pages) { + for (page_id_t page_id : pages) { lock_rec_block_validate(page_id); } |