summaryrefslogtreecommitdiff
path: root/storage
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2016-04-26 23:05:26 +0200
committerSergei Golubchik <serg@mariadb.org>2016-04-26 23:05:26 +0200
commit872649c7baab3a9f7efdda78e49c4bc7dd481d91 (patch)
tree4fffb1a99ca36ccea65e64bcaa81293c40e7539f /storage
parent4995bcffaded6a02106632fb8f259cd3d9048dc4 (diff)
parent4f1ad43992d75676687f29da96dd7c4147247a8f (diff)
downloadmariadb-git-872649c7baab3a9f7efdda78e49c4bc7dd481d91.tar.gz
Merge branch '5.5' into 10.0
Diffstat (limited to 'storage')
-rw-r--r--storage/innobase/dict/dict0crea.cc4
-rw-r--r--storage/myisam/ft_boolean_search.c5
-rw-r--r--storage/myisammrg/ha_myisammrg.cc1
-rw-r--r--storage/tokudb/PerconaFT/cmake_modules/TokuSetupCompiler.cmake18
4 files changed, 16 insertions, 12 deletions
diff --git a/storage/innobase/dict/dict0crea.cc b/storage/innobase/dict/dict0crea.cc
index 3ed97f5f082..dbfdc2c8ef9 100644
--- a/storage/innobase/dict/dict0crea.cc
+++ b/storage/innobase/dict/dict0crea.cc
@@ -1,6 +1,6 @@
/*****************************************************************************
-Copyright (c) 1996, 2014, Oracle and/or its affiliates. All Rights Reserved.
+Copyright (c) 1996, 2016, Oracle and/or its affiliates. All Rights Reserved.
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 the Free Software
@@ -1183,7 +1183,7 @@ dict_create_index_step(
>= UNIV_FORMAT_B);
node->index = dict_index_get_if_in_cache_low(index_id);
- ut_a(err == DB_SUCCESS ? node->index != NULL : node->index == NULL);
+ ut_a((node->index == NULL) == (err != DB_SUCCESS));
if (err != DB_SUCCESS) {
diff --git a/storage/myisam/ft_boolean_search.c b/storage/myisam/ft_boolean_search.c
index 6befe3b2d7a..766f8411ca1 100644
--- a/storage/myisam/ft_boolean_search.c
+++ b/storage/myisam/ft_boolean_search.c
@@ -1,4 +1,4 @@
-/* Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved.
+/* Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
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
@@ -197,7 +197,8 @@ static int ftb_query_add_word(MYSQL_FTPARSER_PARAM *param,
ftbw= (FTB_WORD *)alloc_root(&ftb_param->ftb->mem_root,
sizeof(FTB_WORD) +
(info->trunc ? HA_MAX_KEY_BUFF :
- word_len * ftb_param->ftb->charset->mbmaxlen +
+ (word_len + 1) *
+ ftb_param->ftb->charset->mbmaxlen +
HA_FT_WLEN +
ftb_param->ftb->info->s->rec_reflength));
ftbw->len= word_len + 1;
diff --git a/storage/myisammrg/ha_myisammrg.cc b/storage/myisammrg/ha_myisammrg.cc
index 93722162d86..1a575a2ceea 100644
--- a/storage/myisammrg/ha_myisammrg.cc
+++ b/storage/myisammrg/ha_myisammrg.cc
@@ -1,4 +1,5 @@
/* Copyright (c) 2000, 2011, Oracle and/or its affiliates
+ Copyright (c) 2009, 2016, 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
diff --git a/storage/tokudb/PerconaFT/cmake_modules/TokuSetupCompiler.cmake b/storage/tokudb/PerconaFT/cmake_modules/TokuSetupCompiler.cmake
index c011349c714..40fd27e9c74 100644
--- a/storage/tokudb/PerconaFT/cmake_modules/TokuSetupCompiler.cmake
+++ b/storage/tokudb/PerconaFT/cmake_modules/TokuSetupCompiler.cmake
@@ -61,12 +61,13 @@ endmacro(set_cflags_if_supported_named)
## adds a compiler flag if the compiler supports it
macro(set_cflags_if_supported)
foreach(flag ${ARGN})
- check_c_compiler_flag(${flag} HAVE_C_${flag})
- if (HAVE_C_${flag})
+ STRING(REGEX REPLACE "[-,= ]" "_" res ${flag})
+ check_c_compiler_flag(${flag} HAVE_C_${res})
+ if (HAVE_C_${res})
set(CMAKE_C_FLAGS "${flag} ${CMAKE_C_FLAGS}")
endif ()
- check_cxx_compiler_flag(${flag} HAVE_CXX_${flag})
- if (HAVE_CXX_${flag})
+ check_cxx_compiler_flag(${flag} HAVE_CXX_${res})
+ if (HAVE_CXX_${res})
set(CMAKE_CXX_FLAGS "${flag} ${CMAKE_CXX_FLAGS}")
endif ()
endforeach(flag)
@@ -75,8 +76,9 @@ endmacro(set_cflags_if_supported)
## adds a linker flag if the compiler supports it
macro(set_ldflags_if_supported)
foreach(flag ${ARGN})
- check_cxx_compiler_flag(${flag} HAVE_${flag})
- if (HAVE_${flag})
+ STRING(REGEX REPLACE "[-,= ]" "_" res ${flag})
+ check_cxx_compiler_flag(${flag} HAVE_${res})
+ if (HAVE_${res})
set(CMAKE_EXE_LINKER_FLAGS "${flag} ${CMAKE_EXE_LINKER_FLAGS}")
set(CMAKE_SHARED_LINKER_FLAGS "${flag} ${CMAKE_SHARED_LINKER_FLAGS}")
endif ()
@@ -104,8 +106,8 @@ set_cflags_if_supported(
if (CMAKE_CXX_FLAGS MATCHES -fno-implicit-templates)
# must append this because mysql sets -fno-implicit-templates and we need to override it
- check_cxx_compiler_flag(-fimplicit-templates HAVE_CXX_-fimplicit-templates)
- if (HAVE_CXX_-fimplicit-templates)
+ check_cxx_compiler_flag(-fimplicit-templates HAVE_CXX_IMPLICIT_TEMPLATES)
+ if (HAVE_CXX_IMPLICIT_TEMPLATES)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fimplicit-templates")
endif ()
endif()