Import of pkgsrc-2014Q1

This commit is contained in:
2014-04-17 16:38:45 +02:00
parent 785076ae39
commit 9a8c06dafb
19365 changed files with 828089 additions and 278039 deletions

View File

@@ -1,10 +1,10 @@
# $NetBSD: Makefile,v 1.6 2013/06/18 19:59:35 joerg Exp $
# $NetBSD: Makefile,v 1.11 2014/02/13 07:49:56 adam Exp $
PKGNAME= ${DISTNAME:S/-/-client-/}
SVR4_PKGNAME= mysqc
COMMENT= MySQL 5, a free SQL database (client)
CONFLICTS= {mysql-client-[0-9]*,mysql3-client-[0-9]*}
CONFLICTS= mysql3-client-[0-9]*
.include "Makefile.common"
@@ -26,13 +26,11 @@ REPLACE_PERL+= scripts/mysqldumpslow.sh
REPLACE_PERL+= scripts/mysqlhotcopy.sh
# Replace manual pages which only include other ones with a symbolic link
# if manual compression is activated. The manual pages won't work otherwise.
.if defined(MANZ)
# It is for manual compression is activated or mandoc(1) is used.
post-install:
. for mf in mysql_client_test_embedded.1 mysqltest_embedded.1
.for mf in mysql_client_test_embedded.1 mysqltest_embedded.1
${RM} -f ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/${mf}
${LN} -s ${mf:S/_embedded//} ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/${mf}
. endfor
.endif
.endfor
.include "../../mk/bsd.pkg.mk"

View File

@@ -1,9 +1,9 @@
# $NetBSD: Makefile.common,v 1.7 2013/06/18 19:59:35 joerg Exp $
# $NetBSD: Makefile.common,v 1.13 2014/02/13 07:49:56 adam Exp $
#
# used by databases/mysql56-client/Makefile
# used by databases/mysql56-server/Makefile
DISTNAME= mysql-5.6.12
DISTNAME= mysql-5.6.16
CATEGORIES= databases
MASTER_SITES= ${MASTER_SITE_MYSQL:=MySQL-5.6/}
@@ -60,7 +60,6 @@ CMAKE_ARGS+= -DINSTALL_SQLBENCHDIR="share/mysql/sql-bench"
CMAKE_ARGS+= -DINSTALL_SUPPORTFILESDIR="share/mysql"
CMAKE_ARGS+= -DMYSQL_DATADIR=${MYSQL_DATADIR}
# always use our own readline, not MySQL bundled one
CMAKE_ARGS+= -DWITH_ZLIB="system"
CMAKE_ARGS+= -DDEFAULT_CHARSET=${MYSQL_CHARSET:Q}
CMAKE_ARGS+= -DDEFAULT_COLLATION=${MYSQL_COLLATION:Q}
@@ -111,14 +110,15 @@ SUBST_SED.scr= -e "s,chown,${CHOWN},g"
SUBST_SED.scr+= -e "s,/bin/sh,${RCD_SCRIPTS_SHELL},g"
SUBST_MESSAGE.scr= Fixing scripts.
.include "../../devel/readline/buildlink3.mk"
.if ${_OPSYS_SHLIB_TYPE} == "dylib"
SOEXT="dylib"
.else
SOEXT="so"
.endif
CMAKE_ARGS+= -DWITH_EDITLINE=system
.if !empty(USE_BUILTIN.readline:M[yY][eE][sS]) && !empty(BUILTIN_LIB_FOUND.edit:M[yY][eE][sS])
CMAKE_ARGS+= -DEDITLINE_LIBRARY=${BUILDLINK_PREFIX.readline}/lib/libedit.so
.else
CMAKE_ARGS+= -DEDITLINE_LIBRARY=${BUILDLINK_PREFIX.readline}/lib/libreadline.so
.endif
CMAKE_ARGS+= -DEDITLINE_INCLUDE_DIR=${BUILDLINK_PREFIX.readline}/include/readline
CMAKE_ARGS+= -DEDITLINE_LIBRARY=${BUILDLINK_PREFIX.editline}/lib/libedit.${SOEXT}
CMAKE_ARGS+= -DEDITLINE_INCLUDE_DIR=${BUILDLINK_PREFIX.editline}/include/readline
.include "../../devel/editline/buildlink3.mk"
.include "../../devel/zlib/buildlink3.mk"

View File

@@ -1,4 +1,4 @@
@comment $NetBSD: PLIST,v 1.1 2013/02/13 21:00:02 adam Exp $
@comment $NetBSD: PLIST,v 1.2 2013/07/31 09:51:38 adam Exp $
bin/msql2mysql
bin/mysql
bin/mysql_client_test
@@ -103,11 +103,11 @@ include/mysql/typelib.h
lib/libmysqlclient.a
lib/libmysqlclient.so
lib/libmysqlclient.so.18
lib/libmysqlclient.so.18.0.0
lib/libmysqlclient.so.18.1.0
lib/libmysqlclient_r.a
lib/libmysqlclient_r.so
lib/libmysqlclient_r.so.18
lib/libmysqlclient_r.so.18.0.0
lib/libmysqlclient_r.so.18.1.0
man/man1/comp_err.1
man/man1/innochecksum.1
man/man1/msql2mysql.1

View File

@@ -1,4 +1,4 @@
# $NetBSD: buildlink3.mk,v 1.1 2013/02/13 21:00:02 adam Exp $
# $NetBSD: buildlink3.mk,v 1.2 2014/02/12 23:17:39 tron Exp $
BUILDLINK_TREE+= mysql-client
@@ -6,7 +6,7 @@ BUILDLINK_TREE+= mysql-client
MYSQL_CLIENT_BUILDLINK3_MK:=
BUILDLINK_API_DEPENDS.mysql-client+= mysql-client>=5.6.10
BUILDLINK_ABI_DEPENDS.mysql-client+= mysql-client>=5.6.10
BUILDLINK_ABI_DEPENDS.mysql-client+= mysql-client>=5.6.15nb1
BUILDLINK_PKGSRCDIR.mysql-client?= ../../databases/mysql56-client
BUILDLINK_INCDIRS.mysql-client?= include/mysql
BUILDLINK_LIBDIRS.mysql-client?= lib

View File

@@ -1,116 +1,39 @@
$NetBSD: distinfo,v 1.5 2013/06/04 18:17:25 adam Exp $
$NetBSD: distinfo,v 1.13 2014/02/13 14:38:08 jperkin Exp $
SHA1 (mysql-5.6.12.tar.gz) = 852e168fd39bb24adf8805642be20a59042c2e6c
RMD160 (mysql-5.6.12.tar.gz) = 0088072e353f21fe0b079fe7c26500c822c76819
Size (mysql-5.6.12.tar.gz) = 35876046 bytes
SHA1 (patch-CMakeLists.txt) = 1889afcd79a271d3f9ac0e234c449ef6aa8ca818
SHA1 (mysql-5.6.16.tar.gz) = 64a3b4058e2039d2b812d23c8793f74b4f168cc0
RMD160 (mysql-5.6.16.tar.gz) = 11d21eb50e63776876dccf3a72e19e5de4eec9c2
Size (mysql-5.6.16.tar.gz) = 32821451 bytes
SHA1 (patch-CMakeLists.txt) = b3d0bfc9a23ddbb1ea415e16c35c86e190857bba
SHA1 (patch-client_completion_hash.cc) = b86ec80beac624b2aa21c7587e351ff126400ecb
SHA1 (patch-client_mysqladmin.cc) = e1650ef3695675bcc01375bacdebcb7318218b93
SHA1 (patch-client_sql_string.h) = f26aff4ce4cf6dfef44c85ef95120331ca8fef52
SHA1 (patch-cmake_dtrace.cmake) = e54867464be28ec05534c9b3c38fd54533f652fb
SHA1 (patch-cmake_libutils.cmake) = c3e5ab66d2bef43dc2308369e27550553e0f5356
SHA1 (patch-cmake_plugin.cmake) = 03e7a7debd61e870bd76d5c5b253a620662b3595
SHA1 (patch-cmake_readline.cmake) = f1ec8ccbebb5b7851199bec457d4029c8a9e63dc
SHA1 (patch-cmake_ssl.cmake) = a5a25b00010c6586e5a3e099975ddabe369d4247
SHA1 (patch-include_CMakeLists.txt) = 49d351a958e63c69ad8bfe5c50961fe3751e86c4
SHA1 (patch-include_my__global.h) = d4574aea74221fe3626f3a0c0f5cee9a4d2f36dc
SHA1 (patch-include_my__global.h) = 843b9527faf880eee59cf02239ba601f5985ddfb
SHA1 (patch-include_my_compare.h) = f45bac4b488332a668b0005751856279b67401f5
SHA1 (patch-include_my_net.h) = b08aa36921efd023f9ecaac4cd3fb8a16d200abd
SHA1 (patch-include_my_pthread.h) = ff3bf1fddd04edd7804d810f79de64387464b5ca
SHA1 (patch-include_myisam.h) = c554a594ea0169cb725cfdfe5accaf231eebdc23
SHA1 (patch-libmysql_libmysql.c) = ad78143ca78b7c512e86677b3dd59e497357f289
SHA1 (patch-libmysqld_lib__sql.cc) = ffdd74cece2d7795cb4d8d738f81c2c8dc040a7d
SHA1 (patch-libmysql_CMakeLists.txt) = 229044de6d11b26ee99b25be99b628a9f146b795
SHA1 (patch-mysql-test_CMakeLists.txt) = b7dd562d55678b13ac487aa0ee59bf2551af1f9d
SHA1 (patch-mysys_mf__iocache.c) = 32a396bba5bdbf96104a9c74b695305d7367785a
SHA1 (patch-mysys_my__copy.c) = af2827cdd91d74be1bbce8aba890acf59fa2247e
SHA1 (patch-mysys_my__getwd.c) = ef3a942bf2649c03f936599ea795c6204142e991
SHA1 (patch-mysys__ssl_CMakeLists.txt) = 8393fba7e834a7d97103ef7fc3925d134e018fbb
SHA1 (patch-mysys_stacktrace.c) = 27ddd012c9ca299cfe2b9935b9f99fe603415e7e
SHA1 (patch-scripts_CMakeLists.txt) = 3f4621b3256034c5a3114e98c108658794f06008
SHA1 (patch-scripts_mysqld_safe.sh) = 0784314227657aa0bc3f4a0b4e21c173a86fa94b
SHA1 (patch-sql-common_client.c) = f9ecb9bb381d44ca8b551a27150fc40da887a5e9
SHA1 (patch-sql_CMakeLists.txt) = 83c1e50de6b53a0af5ff010f248dd595745b3eb5
SHA1 (patch-sql_event__db__repository.cc) = 7a7f95b9db61c690aa6edf55503311a13def59ec
SHA1 (patch-sql_field.cc) = 54bd0505251714d18840c79260a18dec92fd3d23
SHA1 (patch-sql_field.h) = bf0d326ffb0ddf6ce31d962c2ddb1cde5042697d
SHA1 (patch-sql_field__conv.cc) = 10847e2fc2b7bb078b125877ffd9efbbc2ba6b28
SHA1 (patch-sql_ha__ndbcluster.cc) = f46816ab5437ef4b2618e83dc6efa6009acf5167
SHA1 (patch-sql_ha__partition.cc) = 712dfefe65f6671c3c834ab07111f828b44b9b92
SHA1 (patch-sql_handler.cc) = e41db8bfae19a7638048ccc37a9f9511f4304b35
SHA1 (patch-sql_handler.h) = e45c9fab750910ef7f02a714c1a4684303cb05a0
SHA1 (patch-sql_item.cc) = cf523f4377788ca2342d6913f22e6e2be21e7b94
SHA1 (patch-sql_item.h) = 8b8be81418254aac383464e9b358268343a9a55d
SHA1 (patch-sql_item__cmpfunc.cc) = 2b2fc56bc4d32d5d831432f5eaee02da3799ac1c
SHA1 (patch-sql_item__cmpfunc.h) = d8dad92cf35cb305de60d3b9a4a02f2b78bd4aed
SHA1 (patch-sql_item__func.cc) = 0516bd8c9ab2a75374b55d78c52853ba0be5ae7a
SHA1 (patch-sql_item__geofunc.cc) = 19d733b40f48ff0b2432c0b7f7f9eb48062bf831
SHA1 (patch-sql_item__strfunc.cc) = a4d7113b090cca62c44c26e2a159d4c321082c44
SHA1 (patch-sql_item__subselect.cc) = eb86202f925a931ac1dca1d087b61e00dc7c5287
SHA1 (patch-sql_item__subselect.h) = b29a58e9373d81d52bcdb113ce5f447123f273a1
SHA1 (patch-sql_item__sum.cc) = a2f2e21bc8ad4ee66fa638d3836b103590e052b9
SHA1 (patch-sql_item__timefunc.cc) = f00211a5d4229767c09df155773386e3dc978073
SHA1 (patch-sql_key.cc) = fe9010507c34187839c6fa9869badcda085487ae
SHA1 (patch-sql_log__event.cc) = ce88494dbadbcebe41499eea6acf2990f4e3c4dc
SHA1 (patch-sql_log_event.h) = a413038ffa29103c75e1d243864615ccb3d9621e
SHA1 (patch-sql_mysqld.cc) = 873100c333038666bcf34ea1f199b202881889cd
SHA1 (patch-sql_net__serv.cc) = caec72290ef36ddbae82bdc09d11f7e2e69a20fc
SHA1 (patch-sql_opt__range.cc) = b6a1d2f9da0b343be634fd4ed0f9729990cf86f4
SHA1 (patch-sql_opt__range.h) = 392cfb7bd5c24d250a8647de84bbb53cb502c5c3
SHA1 (patch-sql_opt__sum.cc) = e949b6622c4d4482a64ed1200fa076ef378a3f69
SHA1 (patch-sql_password.c) = 347fee69188e4ab96e990fc431bad81a57ec0f4d
SHA1 (patch-sql_rpl__mi.cc) = a015854ad02b3ab074b50ec545f1e43ea8b6e416
SHA1 (patch-sql_rpl__slave.cc) = a4a8140c2ebf5336374604c6a521427aa1035119
SHA1 (patch-sql_set__var.cc) = a3760b8fdfb69ea91c2b8e39a2630af61e65068a
SHA1 (patch-sql_sp__head.h) = 6a5dfe3dbb6fcf1017df1762ea72e3831d231508
SHA1 (patch-sql_sp__rcontext.h) = 8e6bd781d8df1b048223e5cf28080ab56e8dc128
SHA1 (patch-sql_sql__acl.cc) = 43b3ab0b169450e125c8a1fc4b72285e28d296c9
SHA1 (patch-sql_sql__admin.cc) = 7cea08b02526133d670ba9d4e2bf6da89527a6d2
SHA1 (patch-sql_sql__base.cc) = 8072a33fd406ea92caca5643a05abbe9271d05cb
SHA1 (patch-sql_sql__bitmap.h) = 5317e0020f8b779ff3440a9da672c2e54a409428
SHA1 (patch-sql_sql__cache.cc) = 52b013571237de20e38f6af7a02bdee40270bfe4
SHA1 (patch-sql_sql__class.cc) = 862c025d2934d5dfd88c294dc7a5e37bbf45ecdb
SHA1 (patch-sql_sql__class.h) = 2c1ea583edac107d20e616ecaf6ef5d50837faaf
SHA1 (patch-sql_sql__delete.cc) = e7873801ad91d9a566bcb2aea7f5c306c2e4bdac
SHA1 (patch-sql_sql__executor.cc) = 8fcb5070c5651fea3207f872e88f33505db168d4
SHA1 (patch-sql_sql__insert.cc) = e2dec778b9545039bfd3a0dae0519b71f8d17953
SHA1 (patch-sql_sql__join__buffer.cc) = 52aab8731d7b2c9be8e4d5ab8b241d316d194d44
SHA1 (patch-sql_sql__lex.cc) = b56d6b0e23123c9561416a1f3da35e3bd4cdac25
SHA1 (patch-sql_sql__lex.h) = 480ff45d47c236297a62143fd9e634f71a3fb138
SHA1 (patch-sql_sql__load.cc) = 2deaed8591f8de74c785551e25c446f1495f6761
SHA1 (patch-sql_sql__optimizer.cc) = 0dd2fbe662fb9f5295fdc5f56b5bb31e21ef2b6e
SHA1 (patch-sql_sql__optimizer.h) = 6104052027b9270540a7050d546a0d013ae86b8c
SHA1 (patch-sql_sql__parse.cc) = 762aa7c8f535cfc31d0af64d8398bf45b83a01f2
SHA1 (patch-sql_sql__partition.cc) = af69c918da14566b45beb757902b03b83aa8e36f
SHA1 (patch-sql_sql__planner.cc) = f3540275174e4ab68950c579d424a2bc118eb292
SHA1 (patch-sql_sql__prepare.cc) = 886ee8ca5863704ddf172eb746c092f308e6ca1c
SHA1 (patch-sql_sql__prepare.h) = 30b520b1dea2b8d8225c528ba58b9231d94a85dd
SHA1 (patch-sql_sql__select.cc) = 30f2df455e1018088efdf896432f4fe35fb9b2f9
SHA1 (patch-sql_sql__select.h) = 324ebb62c71d72e7a948921cfdec9f3401771100
SHA1 (patch-sql_sql__show.cc) = e606a267e86b9c63a46db972739561325fef7ee4
SHA1 (patch-sql_sql__table.cc) = 6f87b68bca9b0a50c50c2392ea342005d53fd5cd
SHA1 (patch-sql_sql__time.cc) = 7a27d9656020676cb8a211befcceb3e3b25670fb
SHA1 (patch-sql_sql__tmp__table.cc) = 5fa1a1b0bb7e245e1f618e7b7536bdf5f69b9528
SHA1 (patch-sql_sql__union.cc) = 0e0dd504eb91512d9ea668d7b09b09d25b3b3c2e
SHA1 (patch-sql_sql__update.cc) = 9a56187727fd1538b059e2d87ca0ec15ebf3e0ff
SHA1 (patch-sql_sql_string.h) = 1ce4d4db59310ea45e384f34e33c0d61935059bf
SHA1 (patch-sql_sys__vars.cc) = f122050ef87e673763db4fa64202139834400d2c
SHA1 (patch-sql_table.cc) = ec9bb0891319918c306b0349fe43647e979bec4c
SHA1 (patch-sql_transaction.cc) = 76316a7f0e7a81f47d194a0a1693b07873922969
SHA1 (patch-sql_tztime.cc) = b17a31afe95cc220b57906d263c5783793c169f4
SHA1 (patch-sql_unireg.cc) = 0d94b247c36838abe5cb683782dd16c05b322f32
SHA1 (patch-storage_federated_ha__federated.cc) = 17e575d4382a6d4c9005be77e7b4254380226e7c
SHA1 (patch-storage_heap_ha__heap.cc) = 8c3e426b34f5bbf2b527e539a91abfb806e14aa5
SHA1 (patch-storage_heap_hp__hash.c) = a3bd242d72e398fcc6fe6450cf05066c1ddae664
SHA1 (patch-storage_myisam_ft__boolean__search.c) = dbace659ea15b5abe14008c1d798414cda708395
SHA1 (patch-storage_myisam_ha__myisam.cc) = 758d5a161a2ef5daf864fa67a0d678d87b8be0aa
SHA1 (patch-storage_myisam_mi__check.c) = 9a3101680f72329158947d04ccce07ef0db821aa
SHA1 (patch-storage_myisam_mi__create.c) = 3267429a40936f1e134f5d309b6c2391d00ce708
SHA1 (patch-storage_myisam_mi__delete.c) = ba1cab21c4cc5b8a98d16742b77d66559cbef374
SHA1 (patch-storage_myisam_mi__dynrec.c) = d4c5d630d016238171805c8d35798293d8595289
SHA1 (patch-storage_myisam_mi__extra.c) = 941125d92943b1b9a3ceccb3cb8cd84a91a0e958
SHA1 (patch-storage_myisam_mi__locking.c) = 63fa46e024f3e78deb052a5cbc0205262848865b
SHA1 (patch-storage_myisam_mi__open.c) = e099113c4192bd582970846499fe927aa2d5affc
SHA1 (patch-storage_myisam_mi__search.c) = e53023188d1d65c858d1b55b365e882182ae332a
SHA1 (patch-storage_myisam_mi__test1.c) = bab69dd7383e58c6291f54dd793b0a3dbef08b8a
SHA1 (patch-storage_myisam_myisamchk.c) = 27507ae61eb49dc971deb7f3665f48fa9660a7b9
SHA1 (patch-storage_archive_CMakeLists.txt) = e739ef4884a154d7e33e8aae24234fd6855119b7
SHA1 (patch-storage_blackhole_CMakeLists.txt) = b9c526783cabd04ea7859d62cb1930ff35f905f8
SHA1 (patch-storage_csv_CMakeLists.txt) = 739accd1fb85b051e28f5c3f16a6c3c0f77d6dae
SHA1 (patch-storage_example_CMakeLists.txt) = a80b1dd3c6020b3fe958db35bebe3bd181136f0d
SHA1 (patch-storage_federated_CMakeLists.txt) = f809504bad63129a06ce455b49ee40cca940891e
SHA1 (patch-storage_heap_CMakeLists.txt) = 0a1a5a7b5e83f14cec43bfa4782dd4bb7b629347
SHA1 (patch-storage_myisam_CMakeLists.txt) = 55897ae78208f78a396776d1082cb5f98631fff8
SHA1 (patch-storage_myisammrg_CMakeLists.txt) = 0a56a16ccaff3fa9de996fec6ffc324af9855a4e
SHA1 (patch-storage_ndb_include_util_Parser.hpp) = 037fc153619bf79ee95cb03a5ac4a71c14952c3a
SHA1 (patch-strings_decimal.c) = 139d86a21d785873e83bd4c97f16fa8180194ebc
SHA1 (patch-vio_vio.c) = 01fe3274ad967b1035e2c354287fd2e57547ab53
SHA1 (patch-vio_viosocket.c) = d3179887e8154f8b7560b083fff6d23bfef7bc39
SHA1 (patch-vio_viossl.c) = 81f1386cd719d87c02ecf4fc47b1f7bb6e6ea389
SHA1 (patch-strings_decimal.c) = 069c9d930c735f74510702baa9bef38aec425903
SHA1 (patch-vio_viossl.c) = 538c08e6ec85d02a7eeead2bb940c91c7f701321

View File

@@ -1,9 +1,9 @@
# $NetBSD: options.mk,v 1.2 2013/02/18 10:17:20 fhajny Exp $
# $NetBSD: options.mk,v 1.3 2014/03/25 13:56:38 jperkin Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.mysql5
# ndb-cluster does not configure with cmake
PKG_SUPPORTED_OPTIONS+= embedded-server ndb-cluster ssl
PKG_SUPPORTED_OPTIONS+= dtrace embedded-server ndb-cluster ssl
PKG_SUGGESTED_OPTIONS+= embedded-server ssl
.include "../../mk/bsd.options.mk"
@@ -15,3 +15,8 @@ CMAKE_ARGS+= -DWITH_SSL=system
.else
CMAKE_ARGS+= -DWITH_SSL=no
.endif
# Enable DTrace support
.if !empty(PKG_OPTIONS:Mdtrace)
CMAKE_ARGS+= -DENABLE_DTRACE=ON
.endif

View File

@@ -1,10 +1,19 @@
$NetBSD: patch-CMakeLists.txt,v 1.1 2013/02/13 21:00:03 adam Exp $
$NetBSD: patch-CMakeLists.txt,v 1.3 2014/02/13 14:38:08 jperkin Exp $
Split configuration between mysql-client and mysql-server.
Build with newer DTrace.
--- CMakeLists.txt.orig 2013-01-22 16:54:49.000000000 +0000
--- CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ CMakeLists.txt
@@ -367,7 +367,6 @@ ADD_SUBDIRECTORY(vio)
@@ -205,6 +205,7 @@ IF(DISABLE_SHARED)
SET(WITHOUT_DYNAMIC_PLUGINS 1)
ENDIF()
OPTION(ENABLED_PROFILING "Enable profiling" ON)
+OPTION(ENABLE_DTRACE "Include support for DTrace probes" OFF)
OPTION(CYBOZU "" OFF)
OPTION(BACKUP_TEST "" OFF)
OPTION(WITHOUT_SERVER OFF)
@@ -443,7 +443,6 @@ ADD_SUBDIRECTORY(vio)
ADD_SUBDIRECTORY(regex)
ADD_SUBDIRECTORY(mysys)
ADD_SUBDIRECTORY(mysys_ssl)
@@ -12,7 +21,7 @@ Split configuration between mysql-client and mysql-server.
IF(WITH_UNIT_TESTS)
ADD_SUBDIRECTORY(unittest)
@@ -378,9 +377,13 @@ IF(WITH_UNIT_TESTS)
@@ -458,9 +457,13 @@ IF(WITH_UNIT_TESTS)
ENDIF()
ADD_SUBDIRECTORY(extra)
@@ -28,7 +37,7 @@ Split configuration between mysql-client and mysql-server.
ADD_SUBDIRECTORY(sql)
ADD_SUBDIRECTORY(sql/share)
ADD_SUBDIRECTORY(libservices)
@@ -393,11 +396,7 @@ IF(NOT WITHOUT_SERVER)
@@ -473,11 +476,7 @@ IF(NOT WITHOUT_SERVER)
ADD_SUBDIRECTORY(mysql-test)
ADD_SUBDIRECTORY(mysql-test/lib/My/SafeProcess)
ADD_SUBDIRECTORY(support-files)

View File

@@ -0,0 +1,21 @@
$NetBSD: patch-cmake_dtrace.cmake,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- cmake/dtrace.cmake.orig 2013-11-17 18:02:53.000000000 +0000
+++ cmake/dtrace.cmake
@@ -35,10 +35,11 @@ MACRO(CHECK_DTRACE)
MARK_AS_ADVANCED(DTRACE)
# On FreeBSD, dtrace does not handle userland tracing yet
- IF(DTRACE AND NOT CMAKE_SYSTEM_NAME MATCHES "FreeBSD"
- AND NOT BUGGY_GCC_NO_DTRACE_MODULES)
- SET(ENABLE_DTRACE ON CACHE BOOL "Enable dtrace")
+ IF(ENABLE_DTRACE AND (CMAKE_SYSTEM_NAME MATCHES "FreeBSD"
+ OR BUGGY_GCC_NO_DTRACE_MODULES OR NOT DTRACE))
+ MESSAGE(FATAL_ERROR "dtrace is not supported on this system")
ENDIF()
+
SET(HAVE_DTRACE ${ENABLE_DTRACE})
IF(CMAKE_SYSTEM_NAME MATCHES "SunOS")
IF(CMAKE_SIZEOF_VOID_P EQUAL 4)

View File

@@ -0,0 +1,56 @@
$NetBSD: patch-cmake_plugin.cmake,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- cmake/plugin.cmake.orig 2013-11-17 18:02:53.000000000 +0000
+++ cmake/plugin.cmake
@@ -21,6 +21,7 @@ INCLUDE(${MYSQL_CMAKE_SCRIPT_DIR}/cmake_
# [STORAGE_ENGINE]
# [MANDATORY|DEFAULT]
# [STATIC_ONLY|DYNAMIC_ONLY]
+# [DTRACE_INSTRUMENTED]
# [MODULE_OUTPUT_NAME module_name]
# [STATIC_OUTPUT_NAME static_name]
# [RECOMPILE_FOR_EMBEDDED]
@@ -47,7 +48,7 @@ ENDMACRO()
MACRO(MYSQL_ADD_PLUGIN)
MYSQL_PARSE_ARGUMENTS(ARG
"LINK_LIBRARIES;DEPENDENCIES;MODULE_OUTPUT_NAME;STATIC_OUTPUT_NAME"
- "STORAGE_ENGINE;STATIC_ONLY;MODULE_ONLY;MANDATORY;DEFAULT;DISABLED;RECOMPILE_FOR_EMBEDDED"
+ "STORAGE_ENGINE;STATIC_ONLY;MODULE_ONLY;MANDATORY;DEFAULT;DISABLED;RECOMPILE_FOR_EMBEDDED;DTRACE_INSTRUMENTED"
${ARGN}
)
@@ -116,7 +117,9 @@ MACRO(MYSQL_ADD_PLUGIN)
IF (WITH_${plugin} AND NOT ARG_MODULE_ONLY)
ADD_LIBRARY(${target} STATIC ${SOURCES})
SET_TARGET_PROPERTIES(${target} PROPERTIES COMPILE_DEFINITONS "MYSQL_SERVER")
- DTRACE_INSTRUMENT(${target})
+ IF (ARG_DTRACE_INSTRUMENTED)
+ DTRACE_INSTRUMENT(${target})
+ ENDIF()
ADD_DEPENDENCIES(${target} GenError ${ARG_DEPENDENCIES})
IF(WITH_EMBEDDED_SERVER)
# Embedded library should contain PIC code and be linkable
@@ -124,7 +127,9 @@ MACRO(MYSQL_ADD_PLUGIN)
IF(ARG_RECOMPILE_FOR_EMBEDDED OR NOT _SKIP_PIC)
# Recompile some plugins for embedded
ADD_CONVENIENCE_LIBRARY(${target}_embedded ${SOURCES})
- DTRACE_INSTRUMENT(${target}_embedded)
+ IF (ARG_DTRACE_INSTRUMENTED)
+ DTRACE_INSTRUMENT(${target}_embedded)
+ ENDIF()
IF(ARG_RECOMPILE_FOR_EMBEDDED)
SET_TARGET_PROPERTIES(${target}_embedded
PROPERTIES COMPILE_DEFINITIONS "MYSQL_SERVER;EMBEDDED_LIBRARY")
@@ -170,7 +175,9 @@ MACRO(MYSQL_ADD_PLUGIN)
ADD_VERSION_INFO(${target} MODULE SOURCES)
ADD_LIBRARY(${target} MODULE ${SOURCES})
- DTRACE_INSTRUMENT(${target})
+ IF (ARG_DTRACE_INSTRUMENTED)
+ DTRACE_INSTRUMENT(${target})
+ ENDIF()
SET_TARGET_PROPERTIES (${target} PROPERTIES PREFIX ""
COMPILE_DEFINITIONS "MYSQL_DYNAMIC_PLUGIN")
TARGET_LINK_LIBRARIES (${target} mysqlservices)

View File

@@ -0,0 +1,18 @@
$NetBSD: patch-cmake_readline.cmake,v 1.1 2013/07/15 02:04:36 ryoon Exp $
* If devel/editline is installed and use base libedit, cmake
readline.h detection fails. Disable mis-detection of
/usr/pkg/editline/readline.h.
--- cmake/readline.cmake.orig 2013-05-21 15:18:39.000000000 +0000
+++ cmake/readline.cmake
@@ -130,9 +130,6 @@ MACRO (MYSQL_USE_BUNDLED_EDITLINE)
ENDMACRO()
MACRO (FIND_SYSTEM_EDITLINE)
- FIND_PATH(FOUND_EDITLINE_READLINE
- NAMES editline/readline.h
- )
IF(FOUND_EDITLINE_READLINE)
SET(EDITLINE_INCLUDE_DIR "${FOUND_EDITLINE_READLINE}/editline")
ELSE()

View File

@@ -1,17 +1,8 @@
$NetBSD: patch-include_my__global.h,v 1.1 2013/04/29 21:16:56 joerg Exp $
$NetBSD: patch-include_my__global.h,v 1.2 2013/12/03 20:02:42 adam Exp $
--- include/my_global.h.orig 2013-04-28 14:06:29.000000000 +0000
+++ include/my_global.h
@@ -465,7 +465,7 @@ typedef unsigned short ushort;
#endif
#define swap_variables(t, a, b) { t dummy; dummy= a; a= b; b= dummy; }
-#define test(a) ((a) ? 1 : 0)
+#define my_test(a) ((a) ? 1 : 0)
#define set_if_bigger(a,b) do { if ((a) < (b)) (a)=(b); } while(0)
#define set_if_smaller(a,b) do { if ((a) > (b)) (a)=(b); } while(0)
#define test_all_bits(a,b) (((a) & (b)) == (b))
@@ -1125,7 +1125,8 @@ typedef char my_bool; /* Small bool */
@@ -1119,7 +1119,8 @@ typedef char my_bool; /* Small bool */
/* Provide __func__ macro definition for platforms that miss it. */
#if __STDC_VERSION__ < 199901L

View File

@@ -1,35 +0,0 @@
$NetBSD: patch-include_myisam.h,v 1.2 2013/05/06 14:41:08 joerg Exp $
Adjust MI_MAX_KEY_LENGTH x4.
--- include/myisam.h.orig 2013-05-05 21:55:07.000000000 +0000
+++ include/myisam.h
@@ -80,8 +80,8 @@ extern "C" {
#define mi_is_key_active(_keymap_,_keyno_) \
(((_keyno_) < MI_KEYMAP_BITS) ? \
- test((_keymap_) & (ULL(1) << (_keyno_))) : \
- test((_keymap_) & MI_KEYMAP_HIGH_MASK))
+ my_test((_keymap_) & (ULL(1) << (_keyno_))) : \
+ my_test((_keymap_) & MI_KEYMAP_HIGH_MASK))
#define mi_set_key_active(_keymap_,_keyno_) \
(_keymap_)|= (((_keyno_) < MI_KEYMAP_BITS) ? \
(ULL(1) << (_keyno_)) : \
@@ -94,7 +94,7 @@ extern "C" {
#else
#define mi_is_key_active(_keymap_,_keyno_) \
- test((_keymap_) & (ULL(1) << (_keyno_)))
+ my_test((_keymap_) & (ULL(1) << (_keyno_)))
#define mi_set_key_active(_keymap_,_keyno_) \
(_keymap_)|= (ULL(1) << (_keyno_))
#define mi_clear_key_active(_keymap_,_keyno_) \
@@ -103,7 +103,7 @@ extern "C" {
#endif
#define mi_is_any_key_active(_keymap_) \
- test((_keymap_))
+ my_test((_keymap_))
#define mi_is_all_keys_active(_keymap_,_keys_) \
((_keymap_) == mi_get_mask_all_keys_active(_keys_))
#define mi_set_all_keys_active(_keymap_,_keys_) \

View File

@@ -0,0 +1,16 @@
$NetBSD: patch-libmysql_CMakeLists.txt,v 1.3 2013/12/03 20:02:42 adam Exp $
* Generate libmysqlclient.so.18.0.0 file and libmysqlclient_r.so.18.0.0 symlink
on FreeBSD to supress PLIST divergence.
--- libmysql/CMakeLists.txt.orig 2013-07-10 16:17:29.000000000 +0000
+++ libmysql/CMakeLists.txt
@@ -224,7 +224,7 @@ IF(NOT DISABLE_SHARED)
COMPONENT SharedLibraries)
IF(UNIX)
# libtool compatability
- IF(CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR APPLE)
+ IF(CMAKE_SYSTEM_NAME MATCHES APPLE)
SET(OS_SHARED_LIB_VERSION "${SHARED_LIB_MAJOR_VERSION}")
ELSE()
SET(OS_SHARED_LIB_VERSION

View File

@@ -1,112 +0,0 @@
$NetBSD: patch-libmysql_libmysql.c,v 1.1 2013/04/29 21:16:56 joerg Exp $
--- libmysql/libmysql.c.orig 2013-04-28 13:52:54.000000000 +0000
+++ libmysql/libmysql.c
@@ -2071,7 +2071,7 @@ static my_bool execute(MYSQL_STMT *stmt,
buff[4]= (char) stmt->flags;
int4store(buff+5, 1); /* iteration count */
- res= test(cli_advanced_command(mysql, COM_STMT_EXECUTE, buff, sizeof(buff),
+ res= my_test(cli_advanced_command(mysql, COM_STMT_EXECUTE, buff, sizeof(buff),
(uchar*) packet, length, 1, stmt) ||
(*mysql->methods->read_query_result)(mysql));
stmt->affected_rows= mysql->affected_rows;
@@ -2559,7 +2559,7 @@ int STDCALL mysql_stmt_execute(MYSQL_STM
reinit_result_set_metadata(stmt);
prepare_to_fetch_result(stmt);
}
- DBUG_RETURN(test(stmt->last_errno));
+ DBUG_RETURN(my_test(stmt->last_errno));
}
@@ -3179,7 +3179,7 @@ static void fetch_string_with_conversion
int err;
double data= my_strntod(&my_charset_latin1, value, length, &endptr, &err);
float fdata= (float) data;
- *param->error= (fdata != data) | test(err);
+ *param->error= (fdata != data) | my_test(err);
floatstore(buffer, fdata);
break;
}
@@ -3187,7 +3187,7 @@ static void fetch_string_with_conversion
{
int err;
double data= my_strntod(&my_charset_latin1, value, length, &endptr, &err);
- *param->error= test(err);
+ *param->error= my_test(err);
doublestore(buffer, data);
break;
}
@@ -3196,7 +3196,7 @@ static void fetch_string_with_conversion
MYSQL_TIME_STATUS status;
MYSQL_TIME *tm= (MYSQL_TIME *)buffer;
str_to_time(value, length, tm, &status);
- *param->error= test(status.warnings);
+ *param->error= my_test(status.warnings);
break;
}
case MYSQL_TYPE_DATE:
@@ -3206,7 +3206,7 @@ static void fetch_string_with_conversion
MYSQL_TIME_STATUS status;
MYSQL_TIME *tm= (MYSQL_TIME *)buffer;
(void) str_to_datetime(value, length, tm, TIME_FUZZY_DATE, &status);
- *param->error= test(status.warnings) &&
+ *param->error= my_test(status.warnings) &&
(param->buffer_type == MYSQL_TYPE_DATE &&
tm->time_type != MYSQL_TIMESTAMP_DATE);
break;
@@ -3331,7 +3331,7 @@ static void fetch_long_with_conversion(M
int error;
value= number_to_datetime(value, (MYSQL_TIME *) buffer, TIME_FUZZY_DATE,
&error);
- *param->error= test(error);
+ *param->error= my_test(error);
break;
}
default:
@@ -3679,7 +3679,7 @@ static void fetch_result_with_conversion
static void fetch_result_tinyint(MYSQL_BIND *param, MYSQL_FIELD *field,
uchar **row)
{
- my_bool field_is_unsigned= test(field->flags & UNSIGNED_FLAG);
+ my_bool field_is_unsigned= my_test(field->flags & UNSIGNED_FLAG);
uchar data= **row;
*(uchar *)param->buffer= data;
*param->error= param->is_unsigned != field_is_unsigned && data > INT_MAX8;
@@ -3689,7 +3689,7 @@ static void fetch_result_tinyint(MYSQL_B
static void fetch_result_short(MYSQL_BIND *param, MYSQL_FIELD *field,
uchar **row)
{
- my_bool field_is_unsigned= test(field->flags & UNSIGNED_FLAG);
+ my_bool field_is_unsigned= my_test(field->flags & UNSIGNED_FLAG);
ushort data= (ushort) sint2korr(*row);
shortstore(param->buffer, data);
*param->error= param->is_unsigned != field_is_unsigned && data > INT_MAX16;
@@ -3700,7 +3700,7 @@ static void fetch_result_int32(MYSQL_BIN
MYSQL_FIELD *field __attribute__((unused)),
uchar **row)
{
- my_bool field_is_unsigned= test(field->flags & UNSIGNED_FLAG);
+ my_bool field_is_unsigned= my_test(field->flags & UNSIGNED_FLAG);
uint32 data= (uint32) sint4korr(*row);
longstore(param->buffer, data);
*param->error= param->is_unsigned != field_is_unsigned && data > INT_MAX32;
@@ -3711,7 +3711,7 @@ static void fetch_result_int64(MYSQL_BIN
MYSQL_FIELD *field __attribute__((unused)),
uchar **row)
{
- my_bool field_is_unsigned= test(field->flags & UNSIGNED_FLAG);
+ my_bool field_is_unsigned= my_test(field->flags & UNSIGNED_FLAG);
ulonglong data= (ulonglong) sint8korr(*row);
*param->error= param->is_unsigned != field_is_unsigned && data > LONGLONG_MAX;
longlongstore(param->buffer, data);
@@ -4705,7 +4705,7 @@ my_bool STDCALL mysql_stmt_close(MYSQL_S
my_free(stmt->extension);
my_free(stmt);
- DBUG_RETURN(test(rc));
+ DBUG_RETURN(my_test(rc));
}
/*

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-libmysqld_lib__sql.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- libmysqld/lib_sql.cc.orig 2013-05-05 21:46:06.000000000 +0000
+++ libmysqld/lib_sql.cc
@@ -337,7 +337,7 @@ static int emb_stmt_execute(MYSQL_STMT *
thd->client_param_count= stmt->param_count;
thd->client_params= stmt->params;
- res= test(emb_advanced_command(stmt->mysql, COM_STMT_EXECUTE, 0, 0,
+ res= my_test(emb_advanced_command(stmt->mysql, COM_STMT_EXECUTE, 0, 0,
header, sizeof(header), 1, stmt) ||
emb_read_query_result(stmt->mysql));
stmt->affected_rows= stmt->mysql->affected_rows;

View File

@@ -0,0 +1,14 @@
$NetBSD: patch-mysys__ssl_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- mysys_ssl/CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ mysys_ssl/CMakeLists.txt
@@ -48,7 +48,6 @@ SET(MYSYS_SSL_SOURCES
ADD_CONVENIENCE_LIBRARY(mysys_ssl ${MYSYS_SSL_SOURCES})
TARGET_LINK_LIBRARIES(mysys_ssl dbug strings ${SSL_LIBRARIES} ${ZLIB_LIBRARY})
-DTRACE_INSTRUMENT(mysys_ssl)
INSTALL_DEBUG_SYMBOLS(mysys_ssl)
IF(MSVC)

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-mysys_mf__iocache.c,v 1.1 2013/04/29 21:16:56 joerg Exp $
--- mysys/mf_iocache.c.orig 2013-04-28 13:55:46.000000000 +0000
+++ mysys/mf_iocache.c
@@ -180,7 +180,7 @@ int init_io_cache(IO_CACHE *info, File f
DBUG_ASSERT(seek_offset == 0);
}
else
- info->seek_not_done= test(seek_offset != pos);
+ info->seek_not_done= my_test(seek_offset != pos);
}
info->disk_writes= 0;

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-mysys_my__copy.c,v 1.1 2013/04/29 21:16:56 joerg Exp $
--- mysys/my_copy.c.orig 2013-04-28 13:55:27.000000000 +0000
+++ mysys/my_copy.c
@@ -63,7 +63,7 @@ int my_copy(const char *from, const char
from_file=to_file= -1;
DBUG_ASSERT(!(MyFlags & (MY_FNABP | MY_NABP))); /* for my_read/my_write */
if (MyFlags & MY_HOLD_ORIGINAL_MODES) /* Copy stat if possible */
- new_file_stat= test(my_stat((char*) to, &new_stat_buff, MYF(0)));
+ new_file_stat= my_test(my_stat((char*) to, &new_stat_buff, MYF(0)));
if ((from_file=my_open(from,O_RDONLY | O_SHARE,MyFlags)) >= 0)
{

View File

@@ -1,20 +0,0 @@
$NetBSD: patch-mysys_my__getwd.c,v 1.1 2013/04/29 21:16:56 joerg Exp $
--- mysys/my_getwd.c.orig 2013-04-28 13:52:00.000000000 +0000
+++ mysys/my_getwd.c
@@ -162,12 +162,12 @@ int test_if_hard_path(register const cha
my_bool has_path(const char *name)
{
- return test(strchr(name, FN_LIBCHAR))
+ return my_test(strchr(name, FN_LIBCHAR))
#if FN_LIBCHAR != '/'
- || test(strchr(name,'/'))
+ || my_test(strchr(name,'/'))
#endif
#ifdef FN_DEVCHAR
- || test(strchr(name, FN_DEVCHAR))
+ || my_test(strchr(name, FN_DEVCHAR))
#endif
;
}

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql-common_client.c,v 1.1 2013/04/29 21:16:56 joerg Exp $
--- sql-common/client.c.orig 2013-04-28 13:57:28.000000000 +0000
+++ sql-common/client.c
@@ -1289,7 +1289,7 @@ void mysql_read_default_options(struct s
options->secure_auth= TRUE;
break;
case OPT_report_data_truncation:
- options->report_data_truncation= opt_arg ? test(atoi(opt_arg)) : 1;
+ options->report_data_truncation= opt_arg ? my_test(atoi(opt_arg)) : 1;
break;
case OPT_plugin_dir:
{
@@ -4296,7 +4296,7 @@ mysql_options(MYSQL *mysql,enum mysql_op
mysql->options.protocol=MYSQL_PROTOCOL_PIPE; /* Force named pipe */
break;
case MYSQL_OPT_LOCAL_INFILE: /* Allow LOAD DATA LOCAL ?*/
- if (!arg || test(*(uint*) arg))
+ if (!arg || my_test(*(uint*) arg))
mysql->options.client_flag|= CLIENT_LOCAL_FILES;
else
mysql->options.client_flag&= ~CLIENT_LOCAL_FILES;
@@ -4342,7 +4342,7 @@ mysql_options(MYSQL *mysql,enum mysql_op
mysql->options.secure_auth= *(my_bool *) arg;
break;
case MYSQL_REPORT_DATA_TRUNCATION:
- mysql->options.report_data_truncation= test(*(my_bool *) arg);
+ mysql->options.report_data_truncation= my_test(*(my_bool *) arg);
break;
case MYSQL_OPT_RECONNECT:
mysql->reconnect= *(my_bool *) arg;

View File

@@ -1,58 +0,0 @@
$NetBSD: patch-sql_event__db__repository.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/event_db_repository.cc.orig 2013-04-05 12:27:18.000000000 +0000
+++ sql/event_db_repository.cc
@@ -469,7 +469,7 @@ Event_db_repository::index_read_for_db_f
end:
event_table->file->ha_index_end();
- DBUG_RETURN(test(ret));
+ DBUG_RETURN(my_test(ret));
}
@@ -743,7 +743,7 @@ end:
thd->mdl_context.rollback_to_savepoint(mdl_savepoint);
thd->variables.sql_mode= saved_mode;
- DBUG_RETURN(test(ret));
+ DBUG_RETURN(my_test(ret));
}
@@ -858,7 +858,7 @@ end:
thd->mdl_context.rollback_to_savepoint(mdl_savepoint);
thd->variables.sql_mode= saved_mode;
- DBUG_RETURN(test(ret));
+ DBUG_RETURN(my_test(ret));
}
@@ -918,7 +918,7 @@ end:
close_thread_tables(thd);
thd->mdl_context.rollback_to_savepoint(mdl_savepoint);
- DBUG_RETURN(test(ret));
+ DBUG_RETURN(my_test(ret));
}
@@ -1153,7 +1153,7 @@ end:
if (save_binlog_row_based)
thd->set_current_stmt_binlog_format_row();
- DBUG_RETURN(test(ret));
+ DBUG_RETURN(my_test(ret));
}
@@ -1230,7 +1230,7 @@ Event_db_repository::check_system_tables
close_mysql_tables(thd);
}
- DBUG_RETURN(test(ret));
+ DBUG_RETURN(my_test(ret));
}
/**

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_field.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/field.cc.orig 2013-04-05 12:27:18.000000000 +0000
+++ sql/field.cc
@@ -1855,7 +1855,7 @@ type_conversion_status Field::store_time
bool Field::optimize_range(uint idx, uint part)
{
- return test(table->file->index_flags(idx, part, 1) & HA_READ_RANGE);
+ return my_test(table->file->index_flags(idx, part, 1) & HA_READ_RANGE);
}
@@ -9514,7 +9514,7 @@ void Create_field::create_length_to_inte
{
pack_length= length / 8;
/* We need one extra byte to store the bits we save among the null bits */
- key_length= pack_length + test(length & 7);
+ key_length= pack_length + my_test(length & 7);
}
break;
case MYSQL_TYPE_NEWDECIMAL:

View File

@@ -1,29 +0,0 @@
$NetBSD: patch-sql_field.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/field.h.orig 2013-05-05 20:53:17.000000000 +0000
+++ sql/field.h
@@ -887,10 +887,10 @@ public:
}
bool is_real_null(my_ptrdiff_t row_offset= 0) const
- { return real_maybe_null() ? test(null_ptr[row_offset] & null_bit) : false; }
+ { return real_maybe_null() ? my_test(null_ptr[row_offset] & null_bit) : false; }
bool is_null_in_record(const uchar *record) const
- { return real_maybe_null() ? test(record[null_offset()] & null_bit) : false; }
+ { return real_maybe_null() ? my_test(record[null_offset()] & null_bit) : false; }
void set_null(my_ptrdiff_t row_offset= 0)
{
@@ -3652,9 +3652,9 @@ public:
{
DBUG_ASSERT(ptr == a || ptr == b);
if (ptr == a)
- return Field_bit::key_cmp(b, bytes_in_rec+test(bit_len));
+ return Field_bit::key_cmp(b, bytes_in_rec+my_test(bit_len));
else
- return Field_bit::key_cmp(a, bytes_in_rec+test(bit_len)) * -1;
+ return Field_bit::key_cmp(a, bytes_in_rec+my_test(bit_len)) * -1;
}
int cmp_binary_offset(uint row_offset)
{ return cmp_offset(row_offset); }

View File

@@ -1,20 +0,0 @@
$NetBSD: patch-sql_field__conv.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/field_conv.cc.orig 2013-05-05 20:55:14.000000000 +0000
+++ sql/field_conv.cc
@@ -330,7 +330,7 @@ static void do_field_int(Copy_field *cop
{
longlong value= copy->from_field->val_int();
copy->to_field->store(value,
- test(copy->from_field->flags & UNSIGNED_FLAG));
+ my_test(copy->from_field->flags & UNSIGNED_FLAG));
}
static void do_field_real(Copy_field *copy)
@@ -898,5 +898,5 @@ type_conversion_status field_conv(Field
return to->store_decimal(from->val_decimal(&buff));
}
else
- return to->store(from->val_int(), test(from->flags & UNSIGNED_FLAG));
+ return to->store(from->val_int(), my_test(from->flags & UNSIGNED_FLAG));
}

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_ha__ndbcluster.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/ha_ndbcluster.cc.orig 2013-05-05 20:55:16.000000000 +0000
+++ sql/ha_ndbcluster.cc
@@ -2807,7 +2807,7 @@ int ha_ndbcluster::open_indexes(THD *thd
if (check_index_fields_not_null(key_info))
m_index[i].null_in_unique_index= TRUE;
- if (error == 0 && test(index_flags(i, 0, 0) & HA_READ_RANGE))
+ if (error == 0 && my_test(index_flags(i, 0, 0) & HA_READ_RANGE))
btree_keys.set_bit(i);
}

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql_ha__partition.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/ha_partition.cc.orig 2013-05-05 20:55:18.000000000 +0000
+++ sql/ha_partition.cc
@@ -3192,7 +3192,7 @@ int ha_partition::open(const char *name,
m_mode= mode;
m_open_test_lock= test_if_locked;
m_part_field_array= m_part_info->full_part_field_array;
- if (get_from_handler_file(name, &table->mem_root, test(m_is_clone_of)))
+ if (get_from_handler_file(name, &table->mem_root, my_test(m_is_clone_of)))
DBUG_RETURN(error);
name_buffer_ptr= m_name_buffer_ptr;
if (populate_partition_name_hash())
@@ -5480,7 +5480,7 @@ int ha_partition::read_range_first(const
m_start_key.key= NULL;
m_index_scan_type= partition_read_range;
- error= common_index_read(m_rec0, test(start_key));
+ error= common_index_read(m_rec0, my_test(start_key));
DBUG_RETURN(error);
}
@@ -7480,7 +7480,7 @@ uint32 ha_partition::calculate_key_hash_
ulong nr1= 1;
ulong nr2= 4;
bool use_51_hash;
- use_51_hash= test((*field_array)->table->part_info->key_algorithm ==
+ use_51_hash= my_test((*field_array)->table->part_info->key_algorithm ==
partition_info::KEY_ALGORITHM_51);
do

View File

@@ -1,58 +0,0 @@
$NetBSD: patch-sql_handler.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/handler.cc.orig 2013-05-05 20:55:20.000000000 +0000
+++ sql/handler.cc
@@ -5722,7 +5722,7 @@ handler::multi_range_read_init(RANGE_SEQ
DBUG_ENTER("handler::multi_range_read_init");
mrr_iter= seq_funcs->init(seq_init_param, n_ranges, mode);
mrr_funcs= *seq_funcs;
- mrr_is_output_sorted= test(mode & HA_MRR_SORTED);
+ mrr_is_output_sorted= my_test(mode & HA_MRR_SORTED);
mrr_have_range= FALSE;
DBUG_RETURN(0);
}
@@ -5778,7 +5778,7 @@ scan_it_again:
&mrr_cur_range.start_key : 0,
mrr_cur_range.end_key.keypart_map ?
&mrr_cur_range.end_key : 0,
- test(mrr_cur_range.range_flag & EQ_RANGE),
+ my_test(mrr_cur_range.range_flag & EQ_RANGE),
mrr_is_output_sorted);
if (result != HA_ERR_END_OF_FILE)
break;
@@ -5875,7 +5875,7 @@ int DsMrr_impl::dsmrr_init(handler *h_ar
rowids_buf= buf->buffer;
- is_mrr_assoc= !test(mode & HA_MRR_NO_ASSOCIATION);
+ is_mrr_assoc= !my_test(mode & HA_MRR_NO_ASSOCIATION);
if (is_mrr_assoc)
status_var_increment(table->in_use->status_var.ha_multi_range_read_init_count);
@@ -6113,7 +6113,7 @@ int DsMrr_impl::dsmrr_fill_buffer()
if (res && res != HA_ERR_END_OF_FILE)
DBUG_RETURN(res);
- dsmrr_eof= test(res == HA_ERR_END_OF_FILE);
+ dsmrr_eof= my_test(res == HA_ERR_END_OF_FILE);
/* Sort the buffer contents by rowid */
uint elem_size= h->ref_length + (int)is_mrr_assoc * sizeof(void*);
@@ -6166,7 +6166,7 @@ int DsMrr_impl::dsmrr_next(char **range_
if (is_mrr_assoc)
memcpy(&cur_range_info, rowids_buf_cur + h->ref_length, sizeof(uchar**));
- rowids_buf_cur += h->ref_length + sizeof(void*) * test(is_mrr_assoc);
+ rowids_buf_cur += h->ref_length + sizeof(void*) * my_test(is_mrr_assoc);
if (h2->mrr_funcs.skip_record &&
h2->mrr_funcs.skip_record(h2->mrr_iter, (char *) cur_range_info, rowid))
continue;
@@ -6388,7 +6388,7 @@ bool DsMrr_impl::get_disk_sweep_mrr_cost
double index_read_cost;
const uint elem_size= h->ref_length +
- sizeof(void*) * (!test(flags & HA_MRR_NO_ASSOCIATION));
+ sizeof(void*) * (!my_test(flags & HA_MRR_NO_ASSOCIATION));
const ha_rows max_buff_entries= *buffer_size / elem_size;
if (!max_buff_entries)

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_handler.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/handler.h.orig 2013-05-05 20:53:53.000000000 +0000
+++ sql/handler.h
@@ -3334,7 +3334,7 @@ static inline const char *ha_resolve_sto
static inline bool ha_check_storage_engine_flag(const handlerton *db_type, uint32 flag)
{
- return db_type == NULL ? FALSE : test(db_type->flags & flag);
+ return db_type == NULL ? FALSE : my_test(db_type->flags & flag);
}
static inline bool ha_storage_engine_is_enabled(const handlerton *db_type)

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_item.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item.cc.orig 2013-04-05 12:27:18.000000000 +0000
+++ sql/item.cc
@@ -2545,7 +2545,7 @@ void Item_field::set_field(Field *field_
field_name= field_par->field_name;
db_name= field_par->table->s->db.str;
alias_name_used= field_par->table->alias_name_used;
- unsigned_flag=test(field_par->flags & UNSIGNED_FLAG);
+ unsigned_flag=my_test(field_par->flags & UNSIGNED_FLAG);
collation.set(field_par->charset(), field_par->derivation(),
field_par->repertoire());
fix_char_length(field_par->char_length());

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql_item.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item.h.orig 2013-05-05 20:52:25.000000000 +0000
+++ sql/item.h
@@ -1637,7 +1637,7 @@ public:
{
if (is_expensive_cache < 0)
is_expensive_cache= walk(&Item::is_expensive_processor, 0, (uchar*)0);
- return test(is_expensive_cache);
+ return my_test(is_expensive_cache);
}
virtual bool can_be_evaluated_now() const;
uint32 max_char_length() const
@@ -2578,7 +2578,7 @@ public:
virtual void print(String *str, enum_query_type query_type);
Item_num *neg() { value= -value; return this; }
uint decimal_precision() const
- { return (uint)(max_length - test(value < 0)); }
+ { return (uint)(max_length - my_test(value < 0)); }
bool eq(const Item *, bool binary_cmp) const;
bool check_partition_func_processor(uchar *bool_arg) { return FALSE;}
};
@@ -4168,7 +4168,7 @@ public:
virtual void store(Item *item);
virtual bool cache_value()= 0;
bool basic_const_item() const
- { return test(example && example->basic_const_item());}
+ { return my_test(example && example->basic_const_item());}
bool walk (Item_processor processor, bool walk_subquery, uchar *argument);
virtual void clear() { null_value= TRUE; value_cached= FALSE; }
bool is_null() { return value_cached ? null_value : example->is_null(); }

View File

@@ -1,101 +0,0 @@
$NetBSD: patch-sql_item__cmpfunc.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_cmpfunc.cc.orig 2013-05-05 20:55:22.000000000 +0000
+++ sql/item_cmpfunc.cc
@@ -497,7 +497,7 @@ static bool convert_constant_item(THD *t
*item) :
#endif
new Item_int_with_ref(field->val_int(), *item,
- test(field->flags & UNSIGNED_FLAG));
+ my_test(field->flags & UNSIGNED_FLAG));
if (tmp)
thd->change_item_tree(item, tmp);
result= 1; // Item was replaced
@@ -1425,8 +1425,8 @@ int Arg_comparator::compare_e_string()
res1= (*a)->val_str(&value1);
res2= (*b)->val_str(&value2);
if (!res1 || !res2)
- return test(res1 == res2);
- return test(sortcmp(res1, res2, cmp_collation.collation) == 0);
+ return my_test(res1 == res2);
+ return my_test(sortcmp(res1, res2, cmp_collation.collation) == 0);
}
@@ -1436,8 +1436,8 @@ int Arg_comparator::compare_e_binary_str
res1= (*a)->val_str(&value1);
res2= (*b)->val_str(&value2);
if (!res1 || !res2)
- return test(res1 == res2);
- return test(stringcmp(res1, res2) == 0);
+ return my_test(res1 == res2);
+ return my_test(stringcmp(res1, res2) == 0);
}
@@ -1492,8 +1492,8 @@ int Arg_comparator::compare_e_real()
double val1= (*a)->val_real();
double val2= (*b)->val_real();
if ((*a)->null_value || (*b)->null_value)
- return test((*a)->null_value && (*b)->null_value);
- return test(val1 == val2);
+ return my_test((*a)->null_value && (*b)->null_value);
+ return my_test(val1 == val2);
}
int Arg_comparator::compare_e_decimal()
@@ -1502,8 +1502,8 @@ int Arg_comparator::compare_e_decimal()
my_decimal *val1= (*a)->val_decimal(&decimal1);
my_decimal *val2= (*b)->val_decimal(&decimal2);
if ((*a)->null_value || (*b)->null_value)
- return test((*a)->null_value && (*b)->null_value);
- return test(my_decimal_cmp(val1, val2) == 0);
+ return my_test((*a)->null_value && (*b)->null_value);
+ return my_test(my_decimal_cmp(val1, val2) == 0);
}
@@ -1541,8 +1541,8 @@ int Arg_comparator::compare_e_real_fixed
double val1= (*a)->val_real();
double val2= (*b)->val_real();
if ((*a)->null_value || (*b)->null_value)
- return test((*a)->null_value && (*b)->null_value);
- return test(val1 == val2 || fabs(val1 - val2) < precision);
+ return my_test((*a)->null_value && (*b)->null_value);
+ return my_test(val1 == val2 || fabs(val1 - val2) < precision);
}
@@ -1616,8 +1616,8 @@ int Arg_comparator::compare_e_time_packe
longlong val1= (*a)->val_time_temporal();
longlong val2= (*b)->val_time_temporal();
if ((*a)->null_value || (*b)->null_value)
- return test((*a)->null_value && (*b)->null_value);
- return test(val1 == val2);
+ return my_test((*a)->null_value && (*b)->null_value);
+ return my_test(val1 == val2);
}
@@ -1708,8 +1708,8 @@ int Arg_comparator::compare_e_int()
longlong val1= (*a)->val_int();
longlong val2= (*b)->val_int();
if ((*a)->null_value || (*b)->null_value)
- return test((*a)->null_value && (*b)->null_value);
- return test(val1 == val2);
+ return my_test((*a)->null_value && (*b)->null_value);
+ return my_test(val1 == val2);
}
/**
@@ -1720,8 +1720,8 @@ int Arg_comparator::compare_e_int_diff_s
longlong val1= (*a)->val_int();
longlong val2= (*b)->val_int();
if ((*a)->null_value || (*b)->null_value)
- return test((*a)->null_value && (*b)->null_value);
- return (val1 >= 0) && test(val1 == val2);
+ return my_test((*a)->null_value && (*b)->null_value);
+ return (val1 >= 0) && my_test(val1 == val2);
}
int Arg_comparator::compare_row()

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_item__cmpfunc.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_cmpfunc.h.orig 2013-05-05 20:53:04.000000000 +0000
+++ sql/item_cmpfunc.h
@@ -400,7 +400,7 @@ public:
Item_func::print_op(str, query_type);
}
- bool is_null() { return test(args[0]->is_null() || args[1]->is_null()); }
+ bool is_null() { return my_test(args[0]->is_null() || args[1]->is_null()); }
const CHARSET_INFO *compare_collation()
{ return cmp.cmp_collation.collation; }
void top_level_item() { abort_on_null= TRUE; }
@@ -950,7 +950,7 @@ public:
/* Compare values number pos1 and pos2 for equality */
bool compare_elems(uint pos1, uint pos2)
{
- return test(compare(collation, base + pos1*size, base + pos2*size));
+ return my_test(compare(collation, base + pos1*size, base + pos2*size));
}
virtual Item_result result_type()= 0;
};

View File

@@ -1,40 +0,0 @@
$NetBSD: patch-sql_item__func.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_func.cc.orig 2013-05-05 20:55:24.000000000 +0000
+++ sql/item_func.cc
@@ -2474,7 +2474,7 @@ void Item_func_round::fix_length_and_dec
case INT_RESULT:
if ((!decimals_to_set && truncate) || (args[0]->decimal_precision() < DECIMAL_LONGLONG_DIGITS))
{
- int length_can_increase= test(!truncate && (val1 < 0) && !val1_unsigned);
+ int length_can_increase= my_test(!truncate && (val1 < 0) && !val1_unsigned);
max_length= args[0]->max_length + length_can_increase;
/* Here we can keep INT_RESULT */
hybrid_type= INT_RESULT;
@@ -4555,7 +4555,7 @@ longlong Item_func_sleep::val_int()
mysql_cond_destroy(&cond);
- return test(!error); // Return 1 killed
+ return my_test(!error); // Return 1 killed
}
@@ -4726,7 +4726,7 @@ bool user_var_entry::realloc(uint length
bool user_var_entry::store(void *from, uint length, Item_result type)
{
// Store strings with end \0
- if (realloc(length + test(type == STRING_RESULT)))
+ if (realloc(length + my_test(type == STRING_RESULT)))
return true;
if (type == STRING_RESULT)
m_ptr[length]= 0; // Store end \0
@@ -6694,7 +6694,7 @@ void Item_func_sp::fix_length_and_dec()
max_length= sp_result_field->field_length;
collation.set(sp_result_field->charset());
maybe_null= 1;
- unsigned_flag= test(sp_result_field->flags & UNSIGNED_FLAG);
+ unsigned_flag= my_test(sp_result_field->flags & UNSIGNED_FLAG);
DBUG_VOID_RETURN;
}

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_item__geofunc.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_geofunc.cc.orig 2013-05-05 20:55:27.000000000 +0000
+++ sql/item_geofunc.cc
@@ -262,7 +262,7 @@ String *Item_func_centroid::val_str(Stri
srid= uint4korr(swkb->ptr());
str->q_append(srid);
- return (null_value= test(geom->centroid(str))) ? 0 : str;
+ return (null_value= my_test(geom->centroid(str))) ? 0 : str;
}

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_item__strfunc.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_strfunc.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/item_strfunc.cc
@@ -100,7 +100,7 @@ bool Item_str_func::fix_fields(THD *thd,
bool res= Item_func::fix_fields(thd, ref);
/*
In Item_str_func::check_well_formed_result() we may set null_value
- flag on the same condition as in test() below.
+ flag on the same condition as in my_test() below.
*/
maybe_null= (maybe_null || thd->is_strict_mode());
return res;

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_item__subselect.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_subselect.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/item_subselect.cc
@@ -3588,7 +3588,7 @@ bool subselect_hash_sj_engine::setup(Lis
/* TODO:
the NULL byte is taken into account in
key_parts[part_no].store_length, so instead of
- cur_ref_buff + test(maybe_null), we could
+ cur_ref_buff + my_test(maybe_null), we could
use that information instead.
*/
cur_ref_buff + (nullable ? 1 : 0),
@@ -3697,7 +3697,7 @@ bool subselect_hash_sj_engine::exec()
goto err; /* purecov: inspected */
materialize_engine->join->exec();
- if ((res= test(materialize_engine->join->error || thd->is_fatal_error)))
+ if ((res= my_test(materialize_engine->join->error || thd->is_fatal_error)))
goto err;
/*

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_item__subselect.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_subselect.h.orig 2013-05-05 20:54:13.000000000 +0000
+++ sql/item_subselect.h
@@ -433,7 +433,7 @@ public:
if ( pushed_cond_guards)
pushed_cond_guards[i]= v;
}
- bool have_guarded_conds() { return test(pushed_cond_guards); }
+ bool have_guarded_conds() { return my_test(pushed_cond_guards); }
Item_in_subselect(Item * left_expr, st_select_lex *select_lex);
Item_in_subselect()

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_item__sum.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_sum.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/item_sum.cc
@@ -3417,7 +3417,7 @@ bool Item_func_group_concat::setup(THD *
{
List<Item> list;
SELECT_LEX *select_lex= thd->lex->current_select;
- const bool order_or_distinct= test(arg_count_order > 0 || distinct);
+ const bool order_or_distinct= my_test(arg_count_order > 0 || distinct);
DBUG_ENTER("Item_func_group_concat::setup");
/*

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_item__timefunc.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/item_timefunc.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/item_timefunc.cc
@@ -1337,7 +1337,7 @@ longlong Item_func_weekday::val_int()
return (longlong) calc_weekday(calc_daynr(ltime.year, ltime.month,
ltime.day),
- odbc_type) + test(odbc_type);
+ odbc_type) + my_test(odbc_type);
}
void Item_func_dayname::fix_length_and_dec()

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql_key.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/key.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/key.cc
@@ -123,7 +123,7 @@ void key_copy(uchar *to_key, uchar *from
{
if (key_part->null_bit)
{
- *to_key++= test(from_record[key_part->null_offset] &
+ *to_key++= my_test(from_record[key_part->null_offset] &
key_part->null_bit);
key_length--;
}
@@ -299,7 +299,7 @@ bool key_cmp_if_same(TABLE *table,const
if (key_part->null_bit)
{
- if (*key != test(table->record[0][key_part->null_offset] &
+ if (*key != my_test(table->record[0][key_part->null_offset] &
key_part->null_bit))
return 1;
if (*key)
@@ -438,7 +438,7 @@ void key_unpack(String *to, TABLE *table
}
}
field_unpack(to, key_part->field, table->record[0], key_part->length,
- test(key_part->key_part_flag & HA_PART_KEY_SEG));
+ my_test(key_part->key_part_flag & HA_PART_KEY_SEG));
}
dbug_tmp_restore_column_map(table->read_set, old_map);
DBUG_VOID_RETURN;

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_log__event.cc,v 1.1 2013/04/29 21:16:56 joerg Exp $
--- sql/log_event.cc.orig 2013-04-28 13:54:43.000000000 +0000
+++ sql/log_event.cc
@@ -642,7 +642,7 @@ static void print_set_option(IO_CACHE* f
{
if (*need_comma)
my_b_printf(file,", ");
- my_b_printf(file,"%s=%d", name, test(flags & option));
+ my_b_printf(file,"%s=%d", name, my_test(flags & option));
*need_comma= 1;
}
}

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql_mysqld.cc,v 1.3 2013/05/06 14:41:08 joerg Exp $
--- sql/mysqld.cc.orig 2013-05-05 21:55:08.000000000 +0000
+++ sql/mysqld.cc
@@ -8268,7 +8268,7 @@ mysqld_get_one_option(int optid,
opt_myisam_log=1;
break;
case (int) OPT_BIN_LOG:
- opt_bin_log= test(argument != disabled_my_option);
+ opt_bin_log= my_test(argument != disabled_my_option);
break;
#ifdef HAVE_REPLICATION
case (int)OPT_REPLICATE_IGNORE_DB:
@@ -8766,7 +8766,7 @@ static int get_options(int *argc_ptr, ch
Set some global variables from the global_system_variables
In most cases the global variables will not be used
*/
- my_disable_locking= myisam_single_user= test(opt_external_locking == 0);
+ my_disable_locking= myisam_single_user= my_test(opt_external_locking == 0);
my_default_record_cache_size=global_system_variables.read_buff_size;
global_system_variables.long_query_time= (ulonglong)
@@ -8793,7 +8793,7 @@ static int get_options(int *argc_ptr, ch
#endif
global_system_variables.engine_condition_pushdown=
- test(global_system_variables.optimizer_switch &
+ my_test(global_system_variables.optimizer_switch &
OPTIMIZER_SWITCH_ENGINE_CONDITION_PUSHDOWN);
opt_readonly= read_only;

View File

@@ -1,40 +0,0 @@
$NetBSD: patch-sql_net__serv.cc,v 1.1 2013/04/29 21:16:56 joerg Exp $
--- sql/net_serv.cc.orig 2013-04-28 13:54:10.000000000 +0000
+++ sql/net_serv.cc
@@ -316,7 +316,7 @@ my_bool my_net_write(NET *net, const uch
#ifndef DEBUG_DATA_PACKETS
DBUG_DUMP("packet_header", buff, NET_HEADER_SIZE);
#endif
- rc= test(net_write_buff(net,packet,len));
+ rc= my_test(net_write_buff(net,packet,len));
MYSQL_NET_WRITE_DONE(rc);
return rc;
}
@@ -390,7 +390,7 @@ net_write_command(NET *net,uchar command
}
int3store(buff,length);
buff[3]= (uchar) net->pkt_nr++;
- rc= test(net_write_buff(net, buff, header_size) ||
+ rc= my_test(net_write_buff(net, buff, header_size) ||
(head_len && net_write_buff(net, header, head_len)) ||
net_write_buff(net, packet, len) || net_flush(net));
MYSQL_NET_WRITE_DONE(rc);
@@ -525,7 +525,7 @@ net_write_raw_loop(NET *net, const uchar
#endif
}
- return test(count);
+ return my_test(count);
}
@@ -700,7 +700,7 @@ static my_bool net_read_raw_loop(NET *ne
#endif
}
- return test(count);
+ return my_test(count);
}

View File

@@ -1,82 +0,0 @@
$NetBSD: patch-sql_opt__range.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/opt_range.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/opt_range.cc
@@ -468,7 +468,7 @@ public:
new_max=arg->max_value; flag_max=arg->max_flag;
}
return new SEL_ARG(field, part, new_min, new_max, flag_min, flag_max,
- test(maybe_flag && arg->maybe_flag));
+ my_test(maybe_flag && arg->maybe_flag));
}
SEL_ARG *clone_first(SEL_ARG *arg)
{ // min <= X < arg->min
@@ -2938,7 +2938,7 @@ free_mem:
Assume that if the user is using 'limit' we will only need to scan
limit rows if we are using a key
*/
- DBUG_RETURN(records ? test(quick) : -1);
+ DBUG_RETURN(records ? my_test(quick) : -1);
}
/****************************************************************************
@@ -3068,7 +3068,7 @@ typedef struct st_part_prune_param
int last_subpart_partno; /* Same as above for supartitioning */
/*
- is_part_keypart[i] == test(keypart #i in partitioning index is a member
+ is_part_keypart[i] == my_test(keypart #i in partitioning index is a member
used in partitioning)
Used to maintain current values of cur_part_fields and cur_subpart_fields
*/
@@ -3951,7 +3951,7 @@ process_next_key_part:
ppar->mark_full_partition_used(ppar->part_info, part_id);
found= TRUE;
}
- res= test(found);
+ res= my_test(found);
}
/*
Restore the "used partitions iterator" to the default setting that
@@ -4979,7 +4979,7 @@ static double ror_scan_selectivity(const
SEL_ARG *sel_arg, *tuple_arg= NULL;
key_part_map keypart_map= 0;
bool cur_covered;
- bool prev_covered= test(bitmap_is_set(&info->covered_fields,
+ bool prev_covered= my_test(bitmap_is_set(&info->covered_fields,
key_part->fieldnr-1));
key_range min_range;
key_range max_range;
@@ -4994,7 +4994,7 @@ static double ror_scan_selectivity(const
sel_arg= sel_arg->next_key_part)
{
DBUG_PRINT("info",("sel_arg step"));
- cur_covered= test(bitmap_is_set(&info->covered_fields,
+ cur_covered= my_test(bitmap_is_set(&info->covered_fields,
key_part[sel_arg->part].fieldnr-1));
if (cur_covered != prev_covered)
{
@@ -9550,12 +9550,12 @@ get_quick_select(PARAM *param,uint idx,S
if (param->table->key_info[param->real_keynr[idx]].flags & HA_SPATIAL)
quick=new QUICK_RANGE_SELECT_GEOM(param->thd, param->table,
param->real_keynr[idx],
- test(parent_alloc),
+ my_test(parent_alloc),
parent_alloc, &create_err);
else
quick=new QUICK_RANGE_SELECT(param->thd, param->table,
param->real_keynr[idx],
- test(parent_alloc), NULL, &create_err);
+ my_test(parent_alloc), NULL, &create_err);
if (quick)
{
@@ -10607,7 +10607,7 @@ int QUICK_RANGE_SELECT::get_next_prefix(
const bool sorted= (mrr_flags & HA_MRR_SORTED);
result= file->read_range_first(last_range->min_keypart_map ? &start_key : 0,
last_range->max_keypart_map ? &end_key : 0,
- test(last_range->flag & EQ_RANGE),
+ my_test(last_range->flag & EQ_RANGE),
sorted);
if (last_range->flag == (UNIQUE_RANGE | EQ_RANGE))
last_range= 0; // Stop searching

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_opt__range.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/opt_range.h.orig 2013-05-05 20:54:50.000000000 +0000
+++ sql/opt_range.h
@@ -596,7 +596,7 @@ public:
THD *thd;
int read_keys_and_merge();
- bool clustered_pk_range() { return test(pk_quick_select); }
+ bool clustered_pk_range() { return my_test(pk_quick_select); }
virtual bool is_valid()
{

View File

@@ -1,40 +0,0 @@
$NetBSD: patch-sql_opt__sum.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/opt_sum.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/opt_sum.cc
@@ -304,7 +304,7 @@ int opt_sum_query(THD *thd,
}
else
{
- maybe_exact_count&= test(table_filled &&
+ maybe_exact_count&= my_test(table_filled &&
(tl->table->file->ha_table_flags() &
HA_HAS_RECORDS));
is_exact_count= FALSE;
@@ -379,7 +379,7 @@ int opt_sum_query(THD *thd,
case Item_sum::MIN_FUNC:
case Item_sum::MAX_FUNC:
{
- int is_max= test(item_sum->sum_func() == Item_sum::MAX_FUNC);
+ int is_max= my_test(item_sum->sum_func() == Item_sum::MAX_FUNC);
/*
If MIN/MAX(expr) is the first part of a key or if all previous
parts of the key is found in the COND, then we can use
@@ -811,7 +811,7 @@ static bool matching_cond(bool max_fl, T
Item *value= args[between && max_fl ? 2 : 1];
value->save_in_field_no_warnings(part->field, true);
if (part->null_bit)
- *key_ptr++= (uchar) test(part->field->is_null());
+ *key_ptr++= (uchar) my_test(part->field->is_null());
part->field->get_key_image(key_ptr, part->length, Field::itRAW);
}
if (is_field_part)
@@ -831,7 +831,7 @@ static bool matching_cond(bool max_fl, T
else if (eq_type)
{
if ((!is_null && !cond->val_int()) ||
- (is_null && !test(part->field->is_null())))
+ (is_null && !my_test(part->field->is_null())))
DBUG_RETURN(FALSE); // Impossible test
}
else if (is_field_part)

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_password.c,v 1.1 2013/04/29 21:16:57 joerg Exp $
--- sql/password.c.orig 2013-04-28 13:53:48.000000000 +0000
+++ sql/password.c
@@ -545,7 +545,7 @@ check_scramble_sha1(const uchar *scrambl
/* now buf supposedly contains hash_stage1: so we can get hash_stage2 */
compute_sha1_hash(hash_stage2_reassured, (const char *) buf, SHA1_HASH_SIZE);
- return test(memcmp(hash_stage2, hash_stage2_reassured, SHA1_HASH_SIZE));
+ return my_test(memcmp(hash_stage2, hash_stage2_reassured, SHA1_HASH_SIZE));
}
my_bool

View File

@@ -1,18 +0,0 @@
$NetBSD: patch-sql_rpl__mi.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/rpl_mi.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/rpl_mi.cc
@@ -478,10 +478,10 @@ bool Master_info::read_info(Rpl_info_han
DBUG_RETURN(true);
}
- ssl= (my_bool) test(temp_ssl);
- ssl_verify_server_cert= (my_bool) test(temp_ssl_verify_server_cert);
+ ssl= (my_bool) my_test(temp_ssl);
+ ssl_verify_server_cert= (my_bool) my_test(temp_ssl_verify_server_cert);
master_log_pos= (my_off_t) temp_master_log_pos;
- auto_position= test(temp_auto_position);
+ auto_position= my_test(temp_auto_position);
if (auto_position != 0 && gtid_mode != 3)
{

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_rpl__slave.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/rpl_slave.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/rpl_slave.cc
@@ -3492,7 +3492,7 @@ apply_event_and_update_pos(Log_event** p
"skipped because event skip counter was non-zero"
};
DBUG_PRINT("info", ("OPTION_BEGIN: %d; IN_STMT: %d",
- test(thd->variables.option_bits & OPTION_BEGIN),
+ my_test(thd->variables.option_bits & OPTION_BEGIN),
rli->get_flag(Relay_log_info::IN_STMT)));
DBUG_PRINT("skip_event", ("%s event was %s",
ev->get_type_str(), explain[reason]));

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_set__var.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/set_var.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/set_var.cc
@@ -566,7 +566,7 @@ int sql_set_variables(THD *thd, List<set
if ((error= var->check(thd)))
goto err;
}
- if (!(error= test(thd->is_error())))
+ if (!(error= my_test(thd->is_error())))
{
it.rewind();
while ((var= it++))

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sp__head.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sp_head.h.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sp_head.h
@@ -859,7 +859,7 @@ public:
else if (m_flags & HAS_SQLCOM_FLUSH)
my_error(ER_STMT_NOT_ALLOWED_IN_SF_OR_TRG, MYF(0), "FLUSH");
- return test(m_flags &
+ return my_test(m_flags &
(CONTAINS_DYNAMIC_SQL|MULTI_RESULTS|HAS_SET_AUTOCOMMIT_STMT|
HAS_COMMIT_OR_ROLLBACK|HAS_SQLCOM_RESET|HAS_SQLCOM_FLUSH));
}

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sp__rcontext.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sp_rcontext.h.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sp_rcontext.h
@@ -453,7 +453,7 @@ public:
bool close(THD *thd);
bool is_open() const
- { return test(m_server_side_cursor); }
+ { return my_test(m_server_side_cursor); }
bool fetch(THD *thd, List<sp_variable> *vars);

View File

@@ -1,61 +0,0 @@
$NetBSD: patch-sql_sql__acl.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_acl.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_acl.cc
@@ -2732,9 +2732,9 @@ update_user_table(THD *thd, TABLE *table
static bool test_if_create_new_users(THD *thd)
{
Security_context *sctx= thd->security_ctx;
- bool create_new_users= test(sctx->master_access & INSERT_ACL) ||
+ bool create_new_users= my_test(sctx->master_access & INSERT_ACL) ||
(!opt_safe_user_create &&
- test(sctx->master_access & CREATE_USER_ACL));
+ my_test(sctx->master_access & CREATE_USER_ACL));
if (!create_new_users)
{
TABLE_LIST tl;
@@ -4449,7 +4449,7 @@ int mysql_table_grant(THD *thd, TABLE_LI
/* Create user if needed */
error=replace_user_table(thd, tables[0].table, Str,
0, revoke_grant, create_new_users,
- test(thd->variables.sql_mode &
+ my_test(thd->variables.sql_mode &
MODE_NO_AUTO_CREATE_USER));
if (error)
{
@@ -4694,7 +4694,7 @@ bool mysql_routine_grant(THD *thd, TABLE
/* Create user if needed */
error=replace_user_table(thd, tables[0].table, Str,
0, revoke_grant, create_new_users,
- test(thd->variables.sql_mode &
+ my_test(thd->variables.sql_mode &
MODE_NO_AUTO_CREATE_USER));
if (error)
{
@@ -4971,7 +4971,7 @@ bool mysql_grant(THD *thd, const char *d
if (replace_user_table(thd, tables[0].table, Str,
(!db ? rights : 0), revoke_grant, create_new_users,
- test(thd->variables.sql_mode &
+ my_test(thd->variables.sql_mode &
MODE_NO_AUTO_CREATE_USER)))
result= -1;
else if (db)
@@ -5470,7 +5470,7 @@ bool check_grant(THD *thd, ulong want_ac
tl && number-- && tl != first_not_own_table;
tl= tl->next_global)
{
- sctx = test(tl->security_ctx) ? tl->security_ctx : thd->security_ctx;
+ sctx = my_test(tl->security_ctx) ? tl->security_ctx : thd->security_ctx;
const ACL_internal_table_access *access=
get_cached_table_access(&tl->grant.m_internal,
@@ -5680,7 +5680,7 @@ bool check_column_grant_in_table_ref(THD
GRANT_INFO *grant;
const char *db_name;
const char *table_name;
- Security_context *sctx= test(table_ref->security_ctx) ?
+ Security_context *sctx= my_test(table_ref->security_ctx) ?
table_ref->security_ctx : thd->security_ctx;
if (table_ref->view || table_ref->field_translation)

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sql__admin.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_admin.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_admin.cc
@@ -1123,7 +1123,7 @@ bool Sql_cmd_repair_table::execute(THD *
thd->enable_slow_log= opt_log_slow_admin_statements;
res= mysql_admin_table(thd, first_table, &thd->lex->check_opt, "repair",
TL_WRITE, 1,
- test(thd->lex->check_opt.sql_flags & TT_USEFRM),
+ my_test(thd->lex->check_opt.sql_flags & TT_USEFRM),
HA_OPEN_FOR_REPAIR, &prepare_for_repair,
&handler::ha_repair, 0);

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql_sql__base.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_base.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_base.cc
@@ -1612,7 +1612,7 @@ bool close_temporary_tables(THD *thd)
/* We always quote db,table names though it is slight overkill */
if (found_user_tables &&
- !(was_quote_show= test(thd->variables.option_bits & OPTION_QUOTE_SHOW_CREATE)))
+ !(was_quote_show= my_test(thd->variables.option_bits & OPTION_QUOTE_SHOW_CREATE)))
{
thd->variables.option_bits |= OPTION_QUOTE_SHOW_CREATE;
}
@@ -8211,7 +8211,7 @@ bool setup_fields(THD *thd, Ref_ptr_arra
thd->lex->allow_sum_func= save_allow_sum_func;
thd->mark_used_columns= save_mark_used_columns;
DBUG_PRINT("info", ("thd->mark_used_columns: %d", thd->mark_used_columns));
- DBUG_RETURN(test(thd->is_error()));
+ DBUG_RETURN(my_test(thd->is_error()));
}
@@ -8775,7 +8775,7 @@ int setup_conds(THD *thd, TABLE_LIST *ta
}
thd->lex->current_select->is_item_list_lookup= save_is_item_list_lookup;
- DBUG_RETURN(test(thd->is_error()));
+ DBUG_RETURN(my_test(thd->is_error()));
err_no_arena:
select_lex->is_item_list_lookup= save_is_item_list_lookup;

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_sql__bitmap.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_bitmap.h.orig 2013-05-05 20:53:40.000000000 +0000
+++ sql/sql_bitmap.h
@@ -60,7 +60,7 @@ public:
intersect(map2buff);
if (map.n_bits > sizeof(ulonglong) * 8)
bitmap_set_above(&map, sizeof(ulonglong),
- test(map2buff & (LL(1) << (sizeof(ulonglong) * 8 - 1))));
+ my_test(map2buff & (LL(1) << (sizeof(ulonglong) * 8 - 1))));
}
void subtract(const Bitmap& map2) { bitmap_subtract(&map, &map2.map); }
void merge(const Bitmap& map2) { bitmap_union(&map, &map2.map); }
@@ -135,7 +135,7 @@ public:
void intersect_extended(ulonglong map2) { map&= map2; }
void subtract(const Bitmap<64>& map2) { map&= ~map2.map; }
void merge(const Bitmap<64>& map2) { map|= map2.map; }
- my_bool is_set(uint n) const { return test(map & (((ulonglong)1) << n)); }
+ my_bool is_set(uint n) const { return my_test(map & (((ulonglong)1) << n)); }
my_bool is_prefix(uint n) const { return map == (((ulonglong)1) << n)-1; }
my_bool is_clear_all() const { return map == (ulonglong)0; }
my_bool is_set_all() const { return map == ~(ulonglong)0; }

View File

@@ -1,56 +0,0 @@
$NetBSD: patch-sql_sql__cache.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_cache.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_cache.cc
@@ -1209,8 +1209,8 @@ void Query_cache::store_query(THD *thd,
Query_cache_query_flags flags;
// fill all gaps between fields with 0 to get repeatable key
memset(&flags, 0, QUERY_CACHE_FLAGS_SIZE);
- flags.client_long_flag= test(thd->client_capabilities & CLIENT_LONG_FLAG);
- flags.client_protocol_41= test(thd->client_capabilities &
+ flags.client_long_flag= my_test(thd->client_capabilities & CLIENT_LONG_FLAG);
+ flags.client_protocol_41= my_test(thd->client_capabilities &
CLIENT_PROTOCOL_41);
/*
Protocol influences result format, so statement results in the binary
@@ -1220,10 +1220,10 @@ void Query_cache::store_query(THD *thd,
flags.protocol_type= (unsigned int) thd->protocol->type();
/* PROTOCOL_LOCAL results are not cached. */
DBUG_ASSERT(flags.protocol_type != (unsigned int) Protocol::PROTOCOL_LOCAL);
- flags.more_results_exists= test(thd->server_status &
+ flags.more_results_exists= my_test(thd->server_status &
SERVER_MORE_RESULTS_EXISTS);
flags.in_trans= thd->in_active_multi_stmt_transaction();
- flags.autocommit= test(thd->server_status & SERVER_STATUS_AUTOCOMMIT);
+ flags.autocommit= my_test(thd->server_status & SERVER_STATUS_AUTOCOMMIT);
flags.pkt_nr= net->pkt_nr;
flags.character_set_client_num=
thd->variables.character_set_client->number;
@@ -1584,14 +1584,14 @@ Query_cache::send_result_to_client(THD *
// fill all gaps between fields with 0 to get repeatable key
memset(&flags, 0, QUERY_CACHE_FLAGS_SIZE);
- flags.client_long_flag= test(thd->client_capabilities & CLIENT_LONG_FLAG);
- flags.client_protocol_41= test(thd->client_capabilities &
+ flags.client_long_flag= my_test(thd->client_capabilities & CLIENT_LONG_FLAG);
+ flags.client_protocol_41= my_test(thd->client_capabilities &
CLIENT_PROTOCOL_41);
flags.protocol_type= (unsigned int) thd->protocol->type();
- flags.more_results_exists= test(thd->server_status &
+ flags.more_results_exists= my_test(thd->server_status &
SERVER_MORE_RESULTS_EXISTS);
flags.in_trans= thd->in_active_multi_stmt_transaction();
- flags.autocommit= test(thd->server_status & SERVER_STATUS_AUTOCOMMIT);
+ flags.autocommit= my_test(thd->server_status & SERVER_STATUS_AUTOCOMMIT);
flags.pkt_nr= thd->net.pkt_nr;
flags.character_set_client_num= thd->variables.character_set_client->number;
flags.character_set_results_num=
@@ -3040,7 +3040,7 @@ my_bool Query_cache::register_all_tables
tmp++)
unlink_table(tmp);
}
- return test(n);
+ return my_test(n);
}

View File

@@ -1,41 +0,0 @@
$NetBSD: patch-sql_sql__class.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_class.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_class.cc
@@ -553,14 +553,14 @@ extern "C" int mysql_tmpfile(const char
extern "C"
int thd_in_lock_tables(const THD *thd)
{
- return test(thd->in_lock_tables);
+ return my_test(thd->in_lock_tables);
}
extern "C"
int thd_tablespace_op(const THD *thd)
{
- return test(thd->tablespace_op);
+ return my_test(thd->tablespace_op);
}
@@ -2535,7 +2535,7 @@ void select_to_file::send_error(uint err
bool select_to_file::send_eof()
{
- int error= test(end_io_cache(&cache));
+ int error= my_test(end_io_cache(&cache));
if (mysql_file_close(file, MYF(MY_WME)) || thd->is_error())
error= true;
@@ -2716,8 +2716,8 @@ select_export::prepare(List<Item> &list,
escape_char= (int) (uchar) (*exchange->escaped)[0];
else
escape_char= -1;
- is_ambiguous_field_sep= test(strchr(ESCAPE_CHARS, field_sep_char));
- is_unsafe_field_sep= test(strchr(NUMERIC_CHARS, field_sep_char));
+ is_ambiguous_field_sep= my_test(strchr(ESCAPE_CHARS, field_sep_char));
+ is_unsafe_field_sep= my_test(strchr(NUMERIC_CHARS, field_sep_char));
line_sep_char= (exchange->line_term->length() ?
(int) (uchar) (*exchange->line_term)[0] : INT_MAX);
if (!field_term_length)

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_sql__class.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_class.h.orig 2013-05-05 20:51:58.000000000 +0000
+++ sql/sql_class.h
@@ -3156,7 +3156,7 @@ public:
}
inline bool is_strict_mode() const
{
- return test(variables.sql_mode & (MODE_STRICT_TRANS_TABLES |
+ return my_test(variables.sql_mode & (MODE_STRICT_TRANS_TABLES |
MODE_STRICT_ALL_TABLES));
}
inline Time_zone *time_zone()
@@ -4608,7 +4608,7 @@ public:
table.str= internal_table_name;
table.length=1;
}
- bool is_derived_table() const { return test(sel); }
+ bool is_derived_table() const { return my_test(sel); }
inline void change_db(char *db_name)
{
db.str= db_name; db.length= (uint) strlen(db_name);

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sql__delete.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_delete.cc.orig 2013-04-05 12:27:18.000000000 +0000
+++ sql/sql_delete.cc
@@ -119,7 +119,7 @@ bool mysql_delete(THD *thd, TABLE_LIST *
DBUG_RETURN(true);
const_cond= (!conds || conds->const_item());
- safe_update=test(thd->variables.option_bits & OPTION_SAFE_UPDATES);
+ safe_update=my_test(thd->variables.option_bits & OPTION_SAFE_UPDATES);
if (safe_update && const_cond)
{
my_message(ER_UPDATE_WITHOUT_KEY_IN_SAFE_MODE,

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_sql__executor.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_executor.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_executor.cc
@@ -1455,7 +1455,7 @@ evaluate_join_record(JOIN *join, JOIN_TA
if (condition)
{
- found= test(condition->val_int());
+ found= my_test(condition->val_int());
if (join->thd->killed)
{
@@ -1863,7 +1863,7 @@ join_read_const_table(JOIN_TAB *tab, POS
{
// We cannot handle outer-joined tables with expensive join conditions here:
DBUG_ASSERT(!(*tab->on_expr_ref)->is_expensive());
- if ((table->null_row= test((*tab->on_expr_ref)->val_int() == 0)))
+ if ((table->null_row= my_test((*tab->on_expr_ref)->val_int() == 0)))
mark_as_null_row(table);
}
if (!table->null_row)

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql_sql__insert.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_insert.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_insert.cc
@@ -759,7 +759,7 @@ bool mysql_insert(THD *thd,TABLE_LIST *t
update,
update_fields,
fields,
- !test(values->elements),
+ !my_test(values->elements),
&can_prune_partitions,
&prune_needs_default_values,
&used_partitions))
@@ -1906,7 +1906,7 @@ int check_that_all_fields_are_given_valu
if (table_list)
{
table_list= table_list->top_table();
- view= test(table_list->view);
+ view= my_test(table_list->view);
}
if (view)
{
@@ -3895,7 +3895,7 @@ static TABLE *create_table_from_items(TH
tmp_table.s->db_create_options=0;
tmp_table.s->db_low_byte_first=
- test(create_info->db_type == myisam_hton ||
+ my_test(create_info->db_type == myisam_hton ||
create_info->db_type == heap_hton);
tmp_table.null_row=tmp_table.maybe_null=0;

View File

@@ -1,51 +0,0 @@
$NetBSD: patch-sql_sql__join__buffer.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_join_buffer.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_join_buffer.cc
@@ -184,8 +184,8 @@ void JOIN_CACHE::calc_record_fields()
for ( ; tab < join_tab ; tab++)
{
calc_used_field_length(join->thd, tab);
- flag_fields+= test(tab->used_null_fields || tab->used_uneven_bit_fields);
- flag_fields+= test(tab->table->maybe_null);
+ flag_fields+= my_test(tab->used_null_fields || tab->used_uneven_bit_fields);
+ flag_fields+= my_test(tab->table->maybe_null);
fields+= tab->used_fields;
blobs+= tab->used_blobs;
@@ -1350,7 +1350,7 @@ void JOIN_CACHE::get_record_by_pos(uchar
bool JOIN_CACHE::get_match_flag_by_pos(uchar *rec_ptr)
{
if (with_match_flag)
- return test(*rec_ptr);
+ return my_test(*rec_ptr);
if (prev_cache)
{
uchar *prev_rec_ptr= prev_cache->get_rec_ref(rec_ptr);
@@ -1593,7 +1593,7 @@ bool JOIN_CACHE::skip_record_if_match()
if (prev_cache)
offset+= prev_cache->get_size_of_rec_offset();
/* Check whether the match flag is on */
- if (test(*(pos+offset)))
+ if (my_test(*(pos+offset)))
{
pos+= size_of_rec_len + get_rec_length(pos);
return TRUE;
@@ -1886,7 +1886,7 @@ enum_nested_loop_state JOIN_CACHE_BNL::j
reset_cache(false);
/* Read each record from the join buffer and look for matches */
- for (cnt= records - test(skip_last) ; cnt; cnt--)
+ for (cnt= records - my_test(skip_last) ; cnt; cnt--)
{
/*
If only the first match is needed and it has been already found for
@@ -2131,7 +2131,7 @@ enum_nested_loop_state JOIN_CACHE::join_
if (!records)
DBUG_RETURN(NESTED_LOOP_OK);
- cnt= records - (is_key_access() ? 0 : test(skip_last));
+ cnt= records - (is_key_access() ? 0 : my_test(skip_last));
/* This function may be called only for inner tables of outer joins */
DBUG_ASSERT(join_tab->first_inner);

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_sql__lex.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_lex.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_lex.cc
@@ -247,7 +247,7 @@ Lex_input_stream::reset(char *buffer, un
m_cpp_utf8_processed_ptr= NULL;
next_state= MY_LEX_START;
found_semicolon= NULL;
- ignore_space= test(m_thd->variables.sql_mode & MODE_IGNORE_SPACE);
+ ignore_space= my_test(m_thd->variables.sql_mode & MODE_IGNORE_SPACE);
stmt_prepare_mode= FALSE;
multi_statements= TRUE;
in_comment=NO_COMMENT;
@@ -3368,7 +3368,7 @@ TABLE_LIST *LEX::unlink_first_table(bool
/*
and from local list if it is not empty
*/
- if ((*link_to_local= test(select_lex.table_list.first)))
+ if ((*link_to_local= my_test(select_lex.table_list.first)))
{
select_lex.context.table_list=
select_lex.context.first_name_resolution_table= first->next_local;

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sql__lex.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_lex.h.orig 2013-05-05 20:52:49.000000000 +0000
+++ sql/sql_lex.h
@@ -1201,7 +1201,7 @@ public:
}
bool requires_prelocking()
{
- return test(query_tables_own_last);
+ return my_test(query_tables_own_last);
}
void mark_as_requiring_prelocking(TABLE_LIST **tables_own_last)
{

View File

@@ -1,40 +0,0 @@
$NetBSD: patch-sql_sql__load.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_load.cc.orig 2013-04-05 12:27:18.000000000 +0000
+++ sql/sql_load.cc
@@ -475,7 +475,7 @@ int mysql_load(THD *thd,sql_exchange *ex
}
}
- if (!(error=test(read_info.error)))
+ if (!(error=my_test(read_info.error)))
{
table->next_number_field=table->found_next_number_field;
@@ -908,7 +908,7 @@ read_fixed_length(THD *thd, COPY_INFO &i
thd->get_stmt_da()->inc_current_row_for_warning();
continue_loop:;
}
- DBUG_RETURN(test(read_info.error));
+ DBUG_RETURN(my_test(read_info.error));
}
@@ -1118,7 +1118,7 @@ read_sep_field(THD *thd, COPY_INFO &info
thd->get_stmt_da()->inc_current_row_for_warning();
continue_loop:;
}
- DBUG_RETURN(test(read_info.error));
+ DBUG_RETURN(my_test(read_info.error));
}
@@ -1280,7 +1280,7 @@ read_xml_field(THD *thd, COPY_INFO &info
thd->get_stmt_da()->inc_current_row_for_warning();
continue_loop:;
}
- DBUG_RETURN(test(read_info.error) || thd->is_error());
+ DBUG_RETURN(my_test(read_info.error) || thd->is_error());
} /* load xml end */

View File

@@ -1,40 +0,0 @@
$NetBSD: patch-sql_sql__optimizer.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_optimizer.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_optimizer.cc
@@ -739,13 +739,13 @@ JOIN::optimize()
need_tmp= ((!plan_is_const() &&
((select_distinct || !simple_order || !simple_group) ||
(group_list && order) ||
- test(select_options & OPTION_BUFFER_RESULT))) ||
+ my_test(select_options & OPTION_BUFFER_RESULT))) ||
(rollup.state != ROLLUP::STATE_NONE && select_distinct));
/* Perform FULLTEXT search before all regular searches */
if (!(select_options & SELECT_DESCRIBE))
{
- init_ftfuncs(thd, select_lex, test(order));
+ init_ftfuncs(thd, select_lex, my_test(order));
optimize_fts_query();
}
@@ -2504,7 +2504,7 @@ simplify_joins(JOIN *join, List<TABLE_LI
NESTED_JOIN *nested_join;
TABLE_LIST *prev_table= 0;
List_iterator<TABLE_LIST> li(*join_list);
- bool straight_join= test(join->select_options & SELECT_STRAIGHT_JOIN);
+ bool straight_join= my_test(join->select_options & SELECT_STRAIGHT_JOIN);
DBUG_ENTER("simplify_joins");
/*
@@ -5416,8 +5416,8 @@ static int sort_keyuse(Key_use *a, Key_u
if (a->keypart != b->keypart)
return (int) (a->keypart - b->keypart);
// Place const values before other ones
- if ((res= test((a->used_tables & ~OUTER_REF_TABLE_BIT)) -
- test((b->used_tables & ~OUTER_REF_TABLE_BIT))))
+ if ((res= my_test((a->used_tables & ~OUTER_REF_TABLE_BIT)) -
+ my_test((b->used_tables & ~OUTER_REF_TABLE_BIT))))
return res;
/* Place rows that are not 'OPTIMIZE_REF_OR_NULL' first */
return (int) ((a->optimize & KEY_OPTIMIZE_REF_OR_NULL) -

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sql__optimizer.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_optimizer.h.orig 2013-05-05 20:54:46.000000000 +0000
+++ sql/sql_optimizer.h
@@ -433,7 +433,7 @@ public:
result= result_arg;
lock= thd_arg->lock;
select_lex= 0; //for safety
- select_distinct= test(select_options & SELECT_DISTINCT);
+ select_distinct= my_test(select_options & SELECT_DISTINCT);
no_order= 0;
simple_order= 0;
simple_group= 0;

View File

@@ -1,36 +0,0 @@
$NetBSD: patch-sql_sql__parse.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_parse.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_parse.cc
@@ -6427,7 +6427,7 @@ TABLE_LIST *st_select_lex::add_table_to_
if (!table)
DBUG_RETURN(0); // End of memory
alias_str= alias ? alias->str : table->table.str;
- if (!test(table_options & TL_OPTION_ALIAS))
+ if (!my_test(table_options & TL_OPTION_ALIAS))
{
enum_ident_name_check ident_check_status=
check_table_name(table->table.str, table->table.length, FALSE);
@@ -6477,10 +6477,10 @@ TABLE_LIST *st_select_lex::add_table_to_
ptr->table_name=table->table.str;
ptr->table_name_length=table->table.length;
ptr->lock_type= lock_type;
- ptr->updating= test(table_options & TL_OPTION_UPDATING);
+ ptr->updating= my_test(table_options & TL_OPTION_UPDATING);
/* TODO: remove TL_OPTION_FORCE_INDEX as it looks like it's not used */
- ptr->force_index= test(table_options & TL_OPTION_FORCE_INDEX);
- ptr->ignore_leaves= test(table_options & TL_OPTION_IGNORE_LEAVES);
+ ptr->force_index= my_test(table_options & TL_OPTION_FORCE_INDEX);
+ ptr->ignore_leaves= my_test(table_options & TL_OPTION_IGNORE_LEAVES);
ptr->derived= table->sel;
if (!ptr->derived && is_infoschema_db(ptr->db, ptr->db_length))
{
@@ -6571,7 +6571,7 @@ TABLE_LIST *st_select_lex::add_table_to_
lex->add_to_query_tables(ptr);
// Pure table aliases do not need to be locked:
- if (!test(table_options & TL_OPTION_ALIAS))
+ if (!my_test(table_options & TL_OPTION_ALIAS))
{
ptr->mdl_request.init(MDL_key::TABLE, ptr->db, ptr->table_name, mdl_type,
MDL_TRANSACTION);

View File

@@ -1,69 +0,0 @@
$NetBSD: patch-sql_sql__partition.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_partition.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_partition.cc
@@ -3294,7 +3294,7 @@ uint32 get_partition_id_cols_list_for_en
}
else
{
- DBUG_RETURN(list_index + test(!tailf));
+ DBUG_RETURN(list_index + my_test(!tailf));
}
} while (max_list_index >= min_list_index);
if (cmp > 0)
@@ -3370,7 +3370,7 @@ uint32 get_list_array_idx_for_endpoint(p
}
else
{
- DBUG_RETURN(list_index + test(left_endpoint ^ include_endpoint));
+ DBUG_RETURN(list_index + my_test(left_endpoint ^ include_endpoint));
}
} while (max_list_index >= min_list_index);
notfound:
@@ -5846,7 +5846,7 @@ static bool mysql_change_partitions(ALTE
if (mysql_trans_commit_alter_copy_data(thd))
error= 1; /* The error has been reported */
- DBUG_RETURN(test(error));
+ DBUG_RETURN(my_test(error));
}
@@ -7720,7 +7720,7 @@ uint32 get_partition_id_cols_range_for_e
loc_part_id * num_columns,
nparts, tailf);
if (!res)
- loc_part_id += test(include_endpoint);
+ loc_part_id += my_test(include_endpoint);
else if (res > 0)
loc_part_id++;
}
@@ -7902,7 +7902,7 @@ int get_part_iter_for_interval_via_mappi
index-in-ordered-array-of-list-constants (for LIST) space.
*/
store_key_image_to_rec(field, min_value, field_len);
- bool include_endp= !test(flags & NEAR_MIN);
+ bool include_endp= !my_test(flags & NEAR_MIN);
part_iter->part_nums.start= get_endpoint(part_info, 1, include_endp);
if (!can_match_multiple_values && part_info->part_expr->null_value)
{
@@ -7937,7 +7937,7 @@ int get_part_iter_for_interval_via_mappi
else
{
store_key_image_to_rec(field, max_value, field_len);
- bool include_endp= !test(flags & NEAR_MAX);
+ bool include_endp= !my_test(flags & NEAR_MAX);
part_iter->part_nums.end= get_endpoint(part_info, 0, include_endp);
if (check_zero_dates &&
!zero_in_start_date &&
@@ -8104,8 +8104,8 @@ int get_part_iter_for_interval_via_walki
if ((ulonglong)b - (ulonglong)a == ~0ULL)
DBUG_RETURN(-1);
- a += test(flags & NEAR_MIN);
- b += test(!(flags & NEAR_MAX));
+ a += my_test(flags & NEAR_MIN);
+ b += my_test(!(flags & NEAR_MAX));
ulonglong n_values= b - a;
/*

View File

@@ -1,58 +0,0 @@
$NetBSD: patch-sql_sql__planner.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_planner.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_planner.cc
@@ -193,7 +193,7 @@ public:
}
}
- bool have_a_case() { return test(handled_sj_equalities); }
+ bool have_a_case() { return my_test(handled_sj_equalities); }
/**
Check if an index can be used for LooseScan, part 1
@@ -571,7 +571,7 @@ void Optimize_table_order::best_access_p
}
else
{
- found_constraint= test(found_part);
+ found_constraint= my_test(found_part);
loose_scan_opt.check_ref_access_part1(s, key, start_key, found_part);
/* Check if we found full key */
@@ -711,7 +711,7 @@ void Optimize_table_order::best_access_p
*/
if (table->quick_keys.is_set(key) && !found_ref && //(C1)
table->quick_key_parts[key] == max_key_part && //(C2)
- table->quick_n_ranges[key] == 1+test(ref_or_null_part)) //(C3)
+ table->quick_n_ranges[key] == 1+my_test(ref_or_null_part)) //(C3)
{
tmp= records= (double) table->quick_rows[key];
}
@@ -813,7 +813,7 @@ void Optimize_table_order::best_access_p
table->quick_key_parts[key] <= max_key_part &&
const_part &
((key_part_map)1 << table->quick_key_parts[key]) &&
- table->quick_n_ranges[key] == 1 + test(ref_or_null_part &
+ table->quick_n_ranges[key] == 1 + my_test(ref_or_null_part &
const_part) &&
records > (double) table->quick_rows[key])
{
@@ -1037,7 +1037,7 @@ void Optimize_table_order::best_access_p
best_key= 0;
/* range/index_merge/ALL/index access method are "independent", so: */
best_ref_depends_map= 0;
- best_uses_jbuf= test(!disable_jbuf);
+ best_uses_jbuf= my_test(!disable_jbuf);
}
}
@@ -1101,7 +1101,7 @@ bool Optimize_table_order::choose_table_
reset_nj_counters(join->join_list);
- const bool straight_join= test(join->select_options & SELECT_STRAIGHT_JOIN);
+ const bool straight_join= my_test(join->select_options & SELECT_STRAIGHT_JOIN);
table_map join_tables; ///< The tables involved in order selection
if (emb_sjm_nest)

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_sql__prepare.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_prepare.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_prepare.cc
@@ -978,7 +978,7 @@ static bool setup_conversion_functions(P
typecode= sint2korr(read_pos);
read_pos+= 2;
- (**it).unsigned_flag= test(typecode & signed_bit);
+ (**it).unsigned_flag= my_test(typecode & signed_bit);
setup_one_conversion_function(thd, *it, (uchar) (typecode & ~signed_bit));
}
}
@@ -2653,7 +2653,7 @@ void mysqld_stmt_execute(THD *thd, char
DBUG_PRINT("exec_query", ("%s", stmt->query()));
DBUG_PRINT("info",("stmt: 0x%lx", (long) stmt));
- open_cursor= test(flags & (ulong) CURSOR_TYPE_READ_ONLY);
+ open_cursor= my_test(flags & (ulong) CURSOR_TYPE_READ_ONLY);
thd->protocol= &thd->protocol_binary;
stmt->execute_loop(&expanded_query, open_cursor, packet, packet_end);

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_sql__prepare.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_prepare.h.orig 2013-05-05 20:54:42.000000000 +0000
+++ sql/sql_prepare.h
@@ -289,7 +289,7 @@ public:
one.
Never fails.
*/
- bool has_next_result() const { return test(m_current_rset->m_next_rset); }
+ bool has_next_result() const { return my_test(m_current_rset->m_next_rset); }
/**
Only valid to call if has_next_result() returned true.
Otherwise the result is undefined.
@@ -297,7 +297,7 @@ public:
bool move_to_next_result()
{
m_current_rset= m_current_rset->m_next_rset;
- return test(m_current_rset);
+ return my_test(m_current_rset);
}
~Ed_connection() { free_old_result(); }

View File

@@ -1,76 +0,0 @@
$NetBSD: patch-sql_sql__select.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_select.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_select.cc
@@ -789,7 +789,7 @@ void JOIN::reset()
}
if (!(select_options & SELECT_DESCRIBE))
- init_ftfuncs(thd, select_lex, test(order));
+ init_ftfuncs(thd, select_lex, my_test(order));
DBUG_VOID_RETURN;
}
@@ -931,7 +931,7 @@ bool JOIN::destroy()
sjm_exec_list.empty();
keyuse.clear();
- DBUG_RETURN(test(error));
+ DBUG_RETURN(my_test(error));
}
@@ -1687,7 +1687,7 @@ bool create_ref_for_key(JOIN *join, JOIN
for (uint part_no= 0 ; part_no < keyparts ; part_no++)
{
keyuse= chosen_keyuses[part_no];
- uint maybe_null= test(keyinfo->key_part[part_no].null_bit);
+ uint maybe_null= my_test(keyinfo->key_part[part_no].null_bit);
if (keyuse->val->type() == Item::FIELD_ITEM)
{
@@ -1925,7 +1925,7 @@ static Item *make_cond_for_index(Item *c
new_cond->argument_list()->push_back(fix);
used_tables|= fix->used_tables();
}
- n_marked += test(item->marker == ICP_COND_USES_INDEX_ONLY);
+ n_marked += my_test(item->marker == ICP_COND_USES_INDEX_ONLY);
}
if (n_marked ==((Item_cond*)cond)->argument_list()->elements)
cond->marker= ICP_COND_USES_INDEX_ONLY;
@@ -1954,7 +1954,7 @@ static Item *make_cond_for_index(Item *c
if (!fix)
return NULL;
new_cond->argument_list()->push_back(fix);
- n_marked += test(item->marker == ICP_COND_USES_INDEX_ONLY);
+ n_marked += my_test(item->marker == ICP_COND_USES_INDEX_ONLY);
}
if (n_marked ==((Item_cond*)cond)->argument_list()->elements)
cond->marker= ICP_COND_USES_INDEX_ONLY;
@@ -2759,7 +2759,7 @@ bool JOIN::setup_materialized_table(JOIN
bool
make_join_readinfo(JOIN *join, ulonglong options, uint no_jbuf_after)
{
- const bool statistics= test(!(join->select_options & SELECT_DESCRIBE));
+ const bool statistics= my_test(!(join->select_options & SELECT_DESCRIBE));
DBUG_ENTER("make_join_readinfo");
@@ -4397,7 +4397,7 @@ test_if_subpart(ORDER *a,ORDER *b)
else
return 0;
}
- return test(!b);
+ return my_test(!b);
}
/**
@@ -5147,7 +5147,7 @@ bool JOIN::make_tmp_tables_info()
or end_write_group()) if JOIN::group is set to false.
*/
// the temporary table was explicitly requested
- DBUG_ASSERT(test(select_options & OPTION_BUFFER_RESULT));
+ DBUG_ASSERT(my_test(select_options & OPTION_BUFFER_RESULT));
// the temporary table does not have a grouping expression
DBUG_ASSERT(!join_tab[curr_tmp_table].table->group);
}

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sql__select.h,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_select.h.orig 2013-05-05 20:54:55.000000000 +0000
+++ sql/sql_select.h
@@ -789,7 +789,7 @@ public:
used_rowid_fields= 1;
used_fieldlength+= table->file->ref_length;
}
- return test(used_rowid_fields);
+ return my_test(used_rowid_fields);
}
bool is_inner_table_of_outer_join()
{

View File

@@ -1,57 +0,0 @@
$NetBSD: patch-sql_sql__show.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_show.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_show.cc
@@ -740,7 +740,7 @@ public:
m_view_access_denied_message_ptr(NULL)
{
- m_sctx = test(m_top_view->security_ctx) ?
+ m_sctx = my_test(m_top_view->security_ctx) ?
m_top_view->security_ctx : thd->security_ctx;
}
@@ -1835,7 +1835,7 @@ static void store_key_options(THD *thd,
end= longlong10_to_str(key_info->block_size, buff, 10);
packet->append(buff, (uint) (end - buff));
}
- DBUG_ASSERT(test(key_info->flags & HA_USES_COMMENT) ==
+ DBUG_ASSERT(my_test(key_info->flags & HA_USES_COMMENT) ==
(key_info->comment.length > 0));
if (key_info->flags & HA_USES_COMMENT)
{
@@ -4634,7 +4634,7 @@ static int get_schema_column_record(THD
#ifndef NO_EMBEDDED_ACCESS_CHECKS
uint col_access;
check_access(thd,SELECT_ACL, db_name->str,
- &tables->grant.privilege, 0, 0, test(tables->schema_table));
+ &tables->grant.privilege, 0, 0, my_test(tables->schema_table));
col_access= get_column_grant(thd, &tables->grant,
db_name->str, table_name->str,
field->field_name) & COL_ACLS;
@@ -4775,13 +4775,13 @@ static my_bool iter_schema_engines(THD *
table->field[1]->store(option_name, strlen(option_name), scs);
table->field[2]->store(plugin_decl(plugin)->descr,
strlen(plugin_decl(plugin)->descr), scs);
- tmp= &yesno[test(hton->commit)];
+ tmp= &yesno[my_test(hton->commit)];
table->field[3]->store(tmp->str, tmp->length, scs);
table->field[3]->set_notnull();
- tmp= &yesno[test(hton->prepare)];
+ tmp= &yesno[my_test(hton->prepare)];
table->field[4]->store(tmp->str, tmp->length, scs);
table->field[4]->set_notnull();
- tmp= &yesno[test(hton->savepoint_set)];
+ tmp= &yesno[my_test(hton->savepoint_set)];
table->field[5]->store(tmp->str, tmp->length, scs);
table->field[5]->set_notnull();
@@ -5357,7 +5357,7 @@ static int get_schema_stat_record(THD *t
else
table->field[14]->store("", 0, cs);
table->field[14]->set_notnull();
- DBUG_ASSERT(test(key_info->flags & HA_USES_COMMENT) ==
+ DBUG_ASSERT(my_test(key_info->flags & HA_USES_COMMENT) ==
(key_info->comment.length > 0));
if (key_info->flags & HA_USES_COMMENT)
table->field[15]->store(key_info->comment.str,

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-sql_sql__table.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_table.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_table.cc
@@ -3870,7 +3870,7 @@ mysql_prepare_create_table(THD *thd, HA_
with length (unlike blobs, where ft code takes data length from a
data prefix, ignoring column->length).
*/
- column->length=test(f_is_blob(sql_field->pack_flag));
+ column->length=my_test(f_is_blob(sql_field->pack_flag));
}
else
{
@@ -7012,7 +7012,7 @@ mysql_prepare_alter_table(THD *thd, TABL
key= new Key(key_type, key_name, strlen(key_name),
&key_create_info,
- test(key_info->flags & HA_GENERATED_KEY),
+ my_test(key_info->flags & HA_GENERATED_KEY),
key_parts);
new_key_list.push_back(key);
}
@@ -9029,7 +9029,7 @@ static bool check_engine(THD *thd, const
handlerton **new_engine= &create_info->db_type;
handlerton *req_engine= *new_engine;
bool no_substitution=
- test(thd->variables.sql_mode & MODE_NO_ENGINE_SUBSTITUTION);
+ my_test(thd->variables.sql_mode & MODE_NO_ENGINE_SUBSTITUTION);
if (!(*new_engine= ha_checktype(thd, ha_legacy_type(req_engine),
no_substitution, 1)))
DBUG_RETURN(true);

View File

@@ -1,17 +0,0 @@
$NetBSD: patch-sql_sql__time.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_time.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_time.cc
@@ -105,9 +105,9 @@ uint calc_week(MYSQL_TIME *l_time, uint
uint days;
ulong daynr=calc_daynr(l_time->year,l_time->month,l_time->day);
ulong first_daynr=calc_daynr(l_time->year,1,1);
- bool monday_first= test(week_behaviour & WEEK_MONDAY_FIRST);
- bool week_year= test(week_behaviour & WEEK_YEAR);
- bool first_weekday= test(week_behaviour & WEEK_FIRST_WEEKDAY);
+ bool monday_first= my_test(week_behaviour & WEEK_MONDAY_FIRST);
+ bool week_year= my_test(week_behaviour & WEEK_YEAR);
+ bool first_weekday= my_test(week_behaviour & WEEK_FIRST_WEEKDAY);
uint weekday=calc_weekday(first_daynr, !monday_first);
*year=l_time->year;

View File

@@ -1,40 +0,0 @@
$NetBSD: patch-sql_sql__tmp__table.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_tmp_table.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_tmp_table.cc
@@ -1006,7 +1006,7 @@ update_hidden:
table->group=group; /* Table is grouped by key */
param->group_buff=group_buff;
share->keys=1;
- share->uniques= test(using_unique_constraint);
+ share->uniques= my_test(using_unique_constraint);
table->key_info= share->key_info= keyinfo;
keyinfo->key_part= key_part_info;
keyinfo->flags=HA_NOSAME;
@@ -1028,7 +1028,7 @@ update_hidden:
{
cur_group->buff=(char*) group_buff;
cur_group->field= field->new_key_field(thd->mem_root, table,
- group_buff + test(maybe_null));
+ group_buff + my_test(maybe_null));
if (!cur_group->field)
goto err; /* purecov: inspected */
@@ -1076,7 +1076,7 @@ update_hidden:
null_pack_length-=hidden_null_pack_length;
keyinfo->user_defined_key_parts=
((field_count-param->hidden_field_count) +
- (share->uniques ? test(null_pack_length) : 0));
+ (share->uniques ? my_test(null_pack_length) : 0));
keyinfo->actual_key_parts= keyinfo->user_defined_key_parts;
table->distinct= 1;
share->keys= 1;
@@ -1400,7 +1400,7 @@ TABLE *create_duplicate_weedout_tmp_tabl
{
DBUG_PRINT("info",("Creating group key in temporary table"));
share->keys=1;
- share->uniques= test(using_unique_constraint);
+ share->uniques= my_test(using_unique_constraint);
table->key_info= table->s->key_info= keyinfo;
keyinfo->key_part=key_part_info;
keyinfo->actual_flags= keyinfo->flags= HA_NOSAME;

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-sql_sql__union.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_union.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_union.cc
@@ -271,7 +271,7 @@ bool st_select_lex_unit::prepare(THD *th
bool is_union_select;
DBUG_ENTER("st_select_lex_unit::prepare");
- describe= test(additional_options & SELECT_DESCRIBE);
+ describe= my_test(additional_options & SELECT_DESCRIBE);
/*
result object should be reassigned even if preparing already done for
@@ -462,7 +462,7 @@ bool st_select_lex_unit::prepare(THD *th
if (global_parameters->ftfunc_list->elements)
create_options= create_options | TMP_TABLE_FORCE_MYISAM;
- if (union_result->create_result_table(thd, &types, test(union_distinct),
+ if (union_result->create_result_table(thd, &types, my_test(union_distinct),
create_options, "", FALSE, TRUE))
goto err;
memset(&result_table_list, 0, sizeof(result_table_list));

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sql__update.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sql_update.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sql_update.cc
@@ -222,7 +222,7 @@ int mysql_update(THD *thd,
ha_rows *found_return, ha_rows *updated_return)
{
bool using_limit= limit != HA_POS_ERROR;
- bool safe_update= test(thd->variables.option_bits & OPTION_SAFE_UPDATES);
+ bool safe_update= my_test(thd->variables.option_bits & OPTION_SAFE_UPDATES);
bool used_key_is_modified= FALSE, transactional_table, will_batch;
int res;
int error= 1;

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_sys__vars.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/sys_vars.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/sys_vars.cc
@@ -2055,7 +2055,7 @@ static bool fix_optimizer_switch(sys_var
{
SV *sv= (type == OPT_GLOBAL) ? &global_system_variables : &thd->variables;
sv->engine_condition_pushdown=
- test(sv->optimizer_switch & OPTIMIZER_SWITCH_ENGINE_CONDITION_PUSHDOWN);
+ my_test(sv->optimizer_switch & OPTIMIZER_SWITCH_ENGINE_CONDITION_PUSHDOWN);
return false;
}

View File

@@ -1,52 +0,0 @@
$NetBSD: patch-sql_table.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/table.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/table.cc
@@ -1076,7 +1076,7 @@ static int open_binary_frm(THD *thd, TAB
}
share->db_record_offset= 1;
/* Set temporarily a good value for db_low_byte_first */
- share->db_low_byte_first= test(legacy_db_type != DB_TYPE_ISAM);
+ share->db_low_byte_first= my_test(legacy_db_type != DB_TYPE_ISAM);
error=4;
share->max_rows= uint4korr(head+18);
share->min_rows= uint4korr(head+22);
@@ -1206,7 +1206,7 @@ static int open_binary_frm(THD *thd, TAB
keyinfo->comment.length);
strpos+= 2 + keyinfo->comment.length;
}
- DBUG_ASSERT(test(keyinfo->flags & HA_USES_COMMENT) ==
+ DBUG_ASSERT(my_test(keyinfo->flags & HA_USES_COMMENT) ==
(keyinfo->comment.length > 0));
}
@@ -2374,9 +2374,9 @@ partititon_err:
else if (outparam->file)
{
handler::Table_flags flags= outparam->file->ha_table_flags();
- outparam->no_replicate= ! test(flags & (HA_BINLOG_STMT_CAPABLE
+ outparam->no_replicate= ! my_test(flags & (HA_BINLOG_STMT_CAPABLE
| HA_BINLOG_ROW_CAPABLE))
- || test(flags & HA_HAS_OWN_BINLOGGING);
+ || my_test(flags & HA_HAS_OWN_BINLOGGING);
}
else
{
@@ -2928,7 +2928,7 @@ File create_frm(THD *thd, const char *na
/* header */
fileinfo[0]=(uchar) 254;
fileinfo[1]= 1;
- fileinfo[2]= FRM_VER+3+ test(create_info->varchar);
+ fileinfo[2]= FRM_VER+3+ my_test(create_info->varchar);
fileinfo[3]= (uchar) ha_legacy_type(
ha_checktype(thd,ha_legacy_type(create_info->db_type),0,0));
@@ -2948,7 +2948,7 @@ File create_frm(THD *thd, const char *na
*/
for (i= 0; i < keys; i++)
{
- DBUG_ASSERT(test(key_info[i].flags & HA_USES_COMMENT) ==
+ DBUG_ASSERT(my_test(key_info[i].flags & HA_USES_COMMENT) ==
(key_info[i].comment.length > 0));
if (key_info[i].flags & HA_USES_COMMENT)
key_comment_total_bytes += 2 + key_info[i].comment.length;

View File

@@ -1,106 +0,0 @@
$NetBSD: patch-sql_transaction.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/transaction.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/transaction.cc
@@ -134,7 +134,7 @@ bool trans_begin(THD *thd, uint flags)
thd->server_status&=
~(SERVER_STATUS_IN_TRANS | SERVER_STATUS_IN_TRANS_READONLY);
DBUG_PRINT("info", ("clearing SERVER_STATUS_IN_TRANS"));
- res= test(ha_commit_trans(thd, TRUE));
+ res= my_test(ha_commit_trans(thd, TRUE));
}
thd->variables.option_bits&= ~OPTION_BEGIN;
@@ -163,7 +163,7 @@ bool trans_begin(THD *thd, uint flags)
compatibility.
*/
const bool user_is_super=
- test(thd->security_ctx->master_access & SUPER_ACL);
+ my_test(thd->security_ctx->master_access & SUPER_ACL);
if (opt_readonly && !user_is_super)
{
my_error(ER_OPTION_PREVENTS_STATEMENT, MYF(0), "--read-only");
@@ -182,7 +182,7 @@ bool trans_begin(THD *thd, uint flags)
if (flags & MYSQL_START_TRANS_OPT_WITH_CONS_SNAPSHOT)
res= ha_start_consistent_snapshot(thd);
- DBUG_RETURN(test(res));
+ DBUG_RETURN(my_test(res));
}
@@ -221,7 +221,7 @@ bool trans_commit(THD *thd)
thd->transaction.all.reset_unsafe_rollback_flags();
thd->lex->start_transaction_opt= 0;
- DBUG_RETURN(test(res));
+ DBUG_RETURN(my_test(res));
}
@@ -263,7 +263,7 @@ bool trans_commit_implicit(THD *thd)
thd->server_status&=
~(SERVER_STATUS_IN_TRANS | SERVER_STATUS_IN_TRANS_READONLY);
DBUG_PRINT("info", ("clearing SERVER_STATUS_IN_TRANS"));
- res= test(ha_commit_trans(thd, TRUE));
+ res= my_test(ha_commit_trans(thd, TRUE));
}
else if (tc_log)
tc_log->commit(thd, true);
@@ -319,7 +319,7 @@ bool trans_rollback(THD *thd)
thd->transaction.all.reset_unsafe_rollback_flags();
thd->lex->start_transaction_opt= 0;
- DBUG_RETURN(test(res));
+ DBUG_RETURN(my_test(res));
}
@@ -382,7 +382,7 @@ bool trans_commit_stmt(THD *thd)
thd->transaction.stmt.reset();
- DBUG_RETURN(test(res));
+ DBUG_RETURN(my_test(res));
}
@@ -588,7 +588,7 @@ bool trans_rollback_to_savepoint(THD *th
if (!res && !binlog_on)
thd->mdl_context.rollback_to_savepoint(sv->mdl_savepoint);
- DBUG_RETURN(test(res));
+ DBUG_RETURN(my_test(res));
}
@@ -630,7 +630,7 @@ bool trans_release_savepoint(THD *thd, L
thd->transaction.savepoints= sv->prev;
- DBUG_RETURN(test(res));
+ DBUG_RETURN(my_test(res));
}
@@ -794,7 +794,7 @@ bool trans_xa_commit(THD *thd)
else if (xa_state == XA_IDLE && thd->lex->xa_opt == XA_ONE_PHASE)
{
int r= ha_commit_trans(thd, TRUE);
- if ((res= test(r)))
+ if ((res= my_test(r)))
my_error(r == 1 ? ER_XA_RBROLLBACK : ER_XAER_RMERR, MYF(0));
}
else if (xa_state == XA_PREPARED && thd->lex->xa_opt == XA_NONE)
@@ -822,9 +822,9 @@ bool trans_xa_commit(THD *thd)
DEBUG_SYNC(thd, "trans_xa_commit_after_acquire_commit_lock");
if (tc_log)
- res= test(tc_log->commit(thd, /* all */ true));
+ res= my_test(tc_log->commit(thd, /* all */ true));
else
- res= test(ha_commit_low(thd, /* all */ true));
+ res= my_test(ha_commit_low(thd, /* all */ true));
if (res)
my_error(ER_XAER_RMERR, MYF(0));

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_tztime.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/tztime.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/tztime.cc
@@ -2643,7 +2643,7 @@ main(int argc, char **argv)
if (TYPE_SIGNED(time_t))
{
t= -100;
- localtime_negative= test(localtime_r(&t, &tmp) != 0);
+ localtime_negative= my_test(localtime_r(&t, &tmp) != 0);
printf("localtime_r %s negative params \
(time_t=%d is %d-%d-%d %d:%d:%d)\n",
(localtime_negative ? "supports" : "doesn't support"), (int)t,

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-sql_unireg.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- sql/unireg.cc.orig 2013-05-05 20:56:04.000000000 +0000
+++ sql/unireg.cc
@@ -287,7 +287,7 @@ bool mysql_create_frm(THD *thd, const ch
maxlength=(uint) next_io_size((ulong) (uint2korr(forminfo_p)+1000));
int2store(forminfo+2,maxlength);
int4store(fileinfo+10,(ulong) (filepos+maxlength));
- fileinfo[26]= (uchar) test((create_info->max_rows == 1) &&
+ fileinfo[26]= (uchar) my_test((create_info->max_rows == 1) &&
(create_info->min_rows == 1) && (keys == 0));
int2store(fileinfo+28,key_info_length);

View File

@@ -0,0 +1,14 @@
$NetBSD: patch-storage_archive_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- storage/archive/CMakeLists.txt.orig 2013-11-17 18:02:54.000000000 +0000
+++ storage/archive/CMakeLists.txt
@@ -14,5 +14,6 @@
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
SET(ARCHIVE_SOURCES azio.c ha_archive.cc ha_archive.h)
-MYSQL_ADD_PLUGIN(archive ${ARCHIVE_SOURCES} STORAGE_ENGINE LINK_LIBRARIES ${ZLIB_LIBRARY})
+MYSQL_ADD_PLUGIN(archive ${ARCHIVE_SOURCES} STORAGE_ENGINE
+ LINK_LIBRARIES ${ZLIB_LIBRARY} DTRACE_INSTRUMENTED)

View File

@@ -0,0 +1,13 @@
$NetBSD: patch-storage_blackhole_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- storage/blackhole/CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ storage/blackhole/CMakeLists.txt
@@ -14,4 +14,5 @@
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
SET(BLACKHOLE_SOURCES ha_blackhole.cc ha_blackhole.h)
-MYSQL_ADD_PLUGIN(blackhole ${BLACKHOLE_SOURCES} STORAGE_ENGINE)
+MYSQL_ADD_PLUGIN(blackhole ${BLACKHOLE_SOURCES} STORAGE_ENGINE
+ DTRACE_INSTRUMENTED)

View File

@@ -0,0 +1,13 @@
$NetBSD: patch-storage_csv_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- storage/csv/CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ storage/csv/CMakeLists.txt
@@ -17,4 +17,5 @@ SET(CSV_PLUGIN_STATIC "csv")
SET(CSV_PLUGIN_MANDATORY TRUE)
SET(CSV_SOURCES ha_tina.cc ha_tina.h transparent_file.cc transparent_file.h)
-MYSQL_ADD_PLUGIN(csv ${CSV_SOURCES} STORAGE_ENGINE MANDATORY)
+MYSQL_ADD_PLUGIN(csv ${CSV_SOURCES} STORAGE_ENGINE
+ MANDATORY DTRACE_INSTRUMENTED)

View File

@@ -0,0 +1,13 @@
$NetBSD: patch-storage_example_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- storage/example/CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ storage/example/CMakeLists.txt
@@ -15,4 +15,5 @@
SET(EXAMPLE_PLUGIN_DYNAMIC "ha_example")
SET(EXAMPLE_SOURCES ha_example.cc)
-MYSQL_ADD_PLUGIN(example ${EXAMPLE_SOURCES} STORAGE_ENGINE MODULE_ONLY)
+MYSQL_ADD_PLUGIN(example ${EXAMPLE_SOURCES} STORAGE_ENGINE MODULE_ONLY
+ DTRACE_INSTRUMENTED)

View File

@@ -0,0 +1,13 @@
$NetBSD: patch-storage_federated_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- storage/federated/CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ storage/federated/CMakeLists.txt
@@ -21,4 +21,5 @@ IF(NOT WITH_FEDERATED AND NOT WITH_FEDER
# mysqld and are optimized away by the linker.
SET(FEDERATED_SOURCES ${FEDERATED_SOURCES} ${CMAKE_SOURCE_DIR}/mysys/string.c)
ENDIF()
-MYSQL_ADD_PLUGIN(federated ${FEDERATED_SOURCES} STORAGE_ENGINE)
+MYSQL_ADD_PLUGIN(federated ${FEDERATED_SOURCES} STORAGE_ENGINE
+ DTRACE_INSTRUMENTED)

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-storage_federated_ha__federated.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- storage/federated/ha_federated.cc.orig 2013-05-05 20:50:46.000000000 +0000
+++ storage/federated/ha_federated.cc
@@ -1463,7 +1463,7 @@ prepare_for_next_key_part:
ptr was incremented by 1. Since store_length still counts null-byte,
we need to subtract 1 from store_length.
*/
- ptr+= store_length - test(key_part->null_bit);
+ ptr+= store_length - my_test(key_part->null_bit);
if (tmp.append(STRING_WITH_LEN(" AND ")))
goto err;
@@ -2105,7 +2105,7 @@ int ha_federated::update_row(const uchar
this? Because we only are updating one record, and LIMIT enforces
this.
*/
- bool has_a_primary_key= test(table->s->primary_key != MAX_KEY);
+ bool has_a_primary_key= my_test(table->s->primary_key != MAX_KEY);
/*
buffers for following strings

View File

@@ -0,0 +1,16 @@
$NetBSD: patch-storage_heap_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- storage/heap/CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ storage/heap/CMakeLists.txt
@@ -22,7 +22,8 @@ SET(HEAP_SOURCES _check.c _rectest.c hp
hp_rename.c hp_rfirst.c hp_rkey.c hp_rlast.c hp_rnext.c hp_rprev.c
hp_rrnd.c hp_rsame.c hp_scan.c hp_static.c hp_update.c hp_write.c)
-MYSQL_ADD_PLUGIN(heap ${HEAP_SOURCES} STORAGE_ENGINE MANDATORY RECOMPILE_FOR_EMBEDDED)
+MYSQL_ADD_PLUGIN(heap ${HEAP_SOURCES} STORAGE_ENGINE MANDATORY
+ RECOMPILE_FOR_EMBEDDED DTRACE_INSTRUMENTED)
IF(WITH_UNIT_TESTS)
ADD_EXECUTABLE(hp_test1 hp_test1.c)

View File

@@ -1,22 +0,0 @@
$NetBSD: patch-storage_heap_ha__heap.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- storage/heap/ha_heap.cc.orig 2013-04-05 12:27:17.000000000 +0000
+++ storage/heap/ha_heap.cc
@@ -97,7 +97,7 @@ const char **ha_heap::bas_ext() const
int ha_heap::open(const char *name, int mode, uint test_if_locked)
{
- internal_table= test(test_if_locked & HA_OPEN_INTERNAL_TABLE);
+ internal_table= my_test(test_if_locked & HA_OPEN_INTERNAL_TABLE);
if (internal_table || (!(file= heap_open(name, mode)) && my_errno == ENOENT))
{
HP_CREATE_INFO create_info;
@@ -113,7 +113,7 @@ int ha_heap::open(const char *name, int
if (rc)
goto end;
- implicit_emptied= test(created_new_share);
+ implicit_emptied= my_test(created_new_share);
if (internal_table)
file= heap_open_from_share(internal_share, mode);
else

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-storage_heap_hp__hash.c,v 1.1 2013/04/29 21:16:57 joerg Exp $
--- storage/heap/hp_hash.c.orig 2013-04-28 13:58:16.000000000 +0000
+++ storage/heap/hp_hash.c
@@ -596,7 +596,7 @@ int hp_key_cmp(HP_KEYDEF *keydef, const
{
if (seg->null_bit)
{
- int found_null=test(rec[seg->null_pos] & seg->null_bit);
+ int found_null=my_test(rec[seg->null_pos] & seg->null_bit);
if (found_null != (int) *key++)
return 1;
if (found_null)
@@ -684,7 +684,7 @@ void hp_make_key(HP_KEYDEF *keydef, ucha
uint char_length= seg->length;
uchar *pos= (uchar*) rec + seg->start;
if (seg->null_bit)
- *key++= test(rec[seg->null_pos] & seg->null_bit);
+ *key++= my_test(rec[seg->null_pos] & seg->null_bit);
if (cs->mbmaxlen > 1)
{
char_length= my_charpos(cs, pos, pos + seg->length,
@@ -717,7 +717,7 @@ uint hp_rb_make_key(HP_KEYDEF *keydef, u
uint char_length;
if (seg->null_bit)
{
- if (!(*key++= 1 - test(rec[seg->null_pos] & seg->null_bit)))
+ if (!(*key++= 1 - my_test(rec[seg->null_pos] & seg->null_bit)))
continue;
}
if (seg->flag & HA_SWAP_KEY)

View File

@@ -0,0 +1,16 @@
$NetBSD: patch-storage_myisam_CMakeLists.txt,v 1.1 2014/02/13 14:38:08 jperkin Exp $
Build with newer DTrace.
--- storage/myisam/CMakeLists.txt.orig 2013-11-17 18:02:53.000000000 +0000
+++ storage/myisam/CMakeLists.txt
@@ -30,7 +30,8 @@ SET(MYISAM_SOURCES ft_boolean_search.c
MYSQL_ADD_PLUGIN(myisam ${MYISAM_SOURCES}
STORAGE_ENGINE
MANDATORY
- RECOMPILE_FOR_EMBEDDED)
+ RECOMPILE_FOR_EMBEDDED
+ DTRACE_INSTRUMENTED)
TARGET_LINK_LIBRARIES(myisam mysys)

View File

@@ -1,13 +0,0 @@
$NetBSD: patch-storage_myisam_ft__boolean__search.c,v 1.1 2013/04/29 21:16:57 joerg Exp $
--- storage/myisam/ft_boolean_search.c.orig 2013-04-28 13:58:51.000000000 +0000
+++ storage/myisam/ft_boolean_search.c
@@ -533,7 +533,7 @@ static void _ftb_init_index_search(FT_IN
{
if (ftbe->flags & FTB_FLAG_NO || /* 2 */
ftbe->up->ythresh - ftbe->up->yweaks >
- (uint) test(ftbe->flags & FTB_FLAG_YES)) /* 1 */
+ (uint) my_test(ftbe->flags & FTB_FLAG_YES)) /* 1 */
{
FTB_EXPR *top_ftbe=ftbe->up;
ftbw->docid[0]=HA_OFFSET_ERROR;

View File

@@ -1,44 +0,0 @@
$NetBSD: patch-storage_myisam_ha__myisam.cc,v 1.1 2013/05/06 14:41:08 joerg Exp $
--- storage/myisam/ha_myisam.cc.orig 2013-05-05 21:01:47.000000000 +0000
+++ storage/myisam/ha_myisam.cc
@@ -464,8 +464,8 @@ int check_definition(MI_KEYDEF *t1_keyin
{
DBUG_PRINT("error", ("Key %d has different definition", i));
DBUG_PRINT("error", ("t1_fulltext= %d, t2_fulltext=%d",
- test(t1_keyinfo[i].flag & HA_FULLTEXT),
- test(t2_keyinfo[i].flag & HA_FULLTEXT)));
+ my_test(t1_keyinfo[i].flag & HA_FULLTEXT),
+ my_test(t2_keyinfo[i].flag & HA_FULLTEXT)));
DBUG_RETURN(1);
}
if (t1_keyinfo[i].flag & HA_SPATIAL && t2_keyinfo[i].flag & HA_SPATIAL)
@@ -475,8 +475,8 @@ int check_definition(MI_KEYDEF *t1_keyin
{
DBUG_PRINT("error", ("Key %d has different definition", i));
DBUG_PRINT("error", ("t1_spatial= %d, t2_spatial=%d",
- test(t1_keyinfo[i].flag & HA_SPATIAL),
- test(t2_keyinfo[i].flag & HA_SPATIAL)));
+ my_test(t1_keyinfo[i].flag & HA_SPATIAL),
+ my_test(t2_keyinfo[i].flag & HA_SPATIAL)));
DBUG_RETURN(1);
}
if ((!mysql_40_compat &&
@@ -1067,7 +1067,7 @@ int ha_myisam::repair(THD *thd, MI_CHECK
share->state.key_map);
uint testflag=param.testflag;
#ifdef HAVE_MMAP
- bool remap= test(share->file_map);
+ bool remap= my_test(share->file_map);
/*
mi_repair*() functions family use file I/O even if memory
mapping is available.
@@ -1609,7 +1609,7 @@ ICP_RESULT index_cond_func_myisam(void *
if (h->end_range && h->compare_key_icp(h->end_range) > 0)
return ICP_OUT_OF_RANGE; /* caller should return HA_ERR_END_OF_FILE already */
- return (ICP_RESULT) test(h->pushed_idx_cond->val_int());
+ return (ICP_RESULT) my_test(h->pushed_idx_cond->val_int());
}
C_MODE_END

View File

@@ -1,67 +0,0 @@
$NetBSD: patch-storage_myisam_mi__check.c,v 1.1 2013/04/29 21:16:57 joerg Exp $
--- storage/myisam/mi_check.c.orig 2013-04-28 14:00:51.000000000 +0000
+++ storage/myisam/mi_check.c
@@ -1159,7 +1159,7 @@ int chk_data_link(MI_CHECK *param, MI_IN
if (param->testflag & (T_EXTEND | T_MEDIUM | T_VERBOSE))
{
if (_mi_rec_check(info,record, info->rec_buff,block_info.rec_len,
- test(info->s->calc_checksum)))
+ my_test(info->s->calc_checksum)))
{
mi_check_print_error(param,"Found wrong packed record at %s",
llstr(start_recpos,llbuff));
@@ -2386,7 +2386,7 @@ int mi_repair_by_sort(MI_CHECK *param, r
if (keyseg[i].flag & HA_SPACE_PACK)
sort_param.key_length+=get_pack_length(keyseg[i].length);
if (keyseg[i].flag & (HA_BLOB_PART | HA_VAR_LENGTH_PART))
- sort_param.key_length+=2 + test(keyseg[i].length >= 127);
+ sort_param.key_length+=2 + my_test(keyseg[i].length >= 127);
if (keyseg[i].flag & HA_NULL_PART)
sort_param.key_length++;
}
@@ -2877,7 +2877,7 @@ int mi_repair_parallel(MI_CHECK *param,
if (keyseg->flag & HA_SPACE_PACK)
sort_param[i].key_length+=get_pack_length(keyseg->length);
if (keyseg->flag & (HA_BLOB_PART | HA_VAR_LENGTH_PART))
- sort_param[i].key_length+=2 + test(keyseg->length >= 127);
+ sort_param[i].key_length+=2 + my_test(keyseg->length >= 127);
if (keyseg->flag & HA_NULL_PART)
sort_param[i].key_length++;
}
@@ -2894,7 +2894,7 @@ int mi_repair_parallel(MI_CHECK *param,
sort_info.total_keys=i;
sort_param[0].master= 1;
sort_param[0].fix_datafile= (my_bool)(! rep_quick);
- sort_param[0].calc_checksum= test(param->testflag & T_CALC_CHECKSUM);
+ sort_param[0].calc_checksum= my_test(param->testflag & T_CALC_CHECKSUM);
if (!ftparser_alloc_param(info))
goto err;
@@ -3564,7 +3564,7 @@ static int sort_get_next_record(MI_SORT_
sort_param->find_length,
(param->testflag & T_QUICK) &&
sort_param->calc_checksum &&
- test(info->s->calc_checksum)))
+ my_test(info->s->calc_checksum)))
{
mi_check_print_info(param,"Found wrong packed record at %s",
llstr(sort_param->start_recpos,llbuff));
@@ -3722,7 +3722,7 @@ int sort_write_record(MI_SORT_PARAM *sor
do
{
- block_length=reclength+ 3 + test(reclength >= (65520-3));
+ block_length=reclength+ 3 + my_test(reclength >= (65520-3));
if (block_length < share->base.min_block_length)
block_length=share->base.min_block_length;
info->update|=HA_STATE_WRITE_AT_END;
@@ -4641,7 +4641,7 @@ static ha_checksum mi_byte_checksum(cons
const uchar *end=buf+length;
for (crc=0; buf != end; buf++)
crc=((crc << 1) + *((uchar*) buf)) +
- test(crc & (((ha_checksum) 1) << (8*sizeof(ha_checksum)-1)));
+ my_test(crc & (((ha_checksum) 1) << (8*sizeof(ha_checksum)-1)));
return crc;
}

View File

@@ -1,31 +0,0 @@
$NetBSD: patch-storage_myisam_mi__create.c,v 1.1 2013/04/29 21:16:57 joerg Exp $
--- storage/myisam/mi_create.c.orig 2013-04-28 14:00:49.000000000 +0000
+++ storage/myisam/mi_create.c
@@ -134,7 +134,7 @@ int mi_create(const char *name,uint keys
pack_reclength++;
min_pack_length++;
/* We must test for 257 as length includes pack-length */
- if (test(rec->length >= 257))
+ if (my_test(rec->length >= 257))
{
long_varchar_count++;
pack_reclength+= 2; /* May be packed on 3 bytes */
@@ -193,7 +193,7 @@ int mi_create(const char *name,uint keys
packed=(packed+7)/8;
if (pack_reclength != INT_MAX32)
pack_reclength+= reclength+packed +
- test(test_all_bits(options, HA_OPTION_CHECKSUM | HA_OPTION_PACK_RECORD));
+ my_test(test_all_bits(options, HA_OPTION_CHECKSUM | HA_OPTION_PACK_RECORD));
min_pack_length+=packed;
if (!ci->data_file_length && ci->max_rows)
@@ -544,7 +544,7 @@ int mi_create(const char *name,uint keys
share.base.records=ci->max_rows;
share.base.reloc= ci->reloc_rows;
share.base.reclength=real_reclength;
- share.base.pack_reclength=reclength+ test(options & HA_OPTION_CHECKSUM);
+ share.base.pack_reclength=reclength+ my_test(options & HA_OPTION_CHECKSUM);
share.base.max_pack_length=pack_reclength;
share.base.min_pack_length=min_pack_length;
share.base.pack_bits=packed;

Some files were not shown because too many files have changed in this diff Show More