diff options
author | Sergey Vojtovich <svoj@mariadb.org> | 2014-02-19 14:05:15 +0400 |
---|---|---|
committer | Sergey Vojtovich <svoj@mariadb.org> | 2014-02-19 14:05:15 +0400 |
commit | d12c7adf715677b118104d4e5adf6f978c27b4ee (patch) | |
tree | 04cdbaf4509cbe485cb992e271ab8d711a867011 /sql/key.cc | |
parent | fd1437dfe532ed78ce2a1c8e05a989fcbf79832e (diff) | |
download | mariadb-git-d12c7adf715677b118104d4e5adf6f978c27b4ee.tar.gz |
MDEV-5314 - Compiling fails on OSX using clang
This is port of fix for MySQL BUG#17647863.
revno: 5572
revision-id: jon.hauglid@oracle.com-20131030232243-b0pw98oy72uka2sj
committer: Jon Olav Hauglid <jon.hauglid@oracle.com>
timestamp: Thu 2013-10-31 00:22:43 +0100
message:
Bug#17647863: MYSQL DOES NOT COMPILE ON OSX 10.9 GM
Rename test() macro to MY_TEST() to avoid conflict with libc++.
Diffstat (limited to 'sql/key.cc')
-rw-r--r-- | sql/key.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sql/key.cc b/sql/key.cc index 8ba3d48e8dc..2df9c7e0cb5 100644 --- a/sql/key.cc +++ b/sql/key.cc @@ -126,8 +126,8 @@ void key_copy(uchar *to_key, uchar *from_record, KEY *key_info, { if (key_part->null_bit) { - *to_key++= test(from_record[key_part->null_offset] & - key_part->null_bit); + *to_key++= MY_TEST(from_record[key_part->null_offset] & + key_part->null_bit); key_length--; if (to_key[-1]) { @@ -300,8 +300,8 @@ bool key_cmp_if_same(TABLE *table,const uchar *key,uint idx,uint key_length) if (key_part->null_bit) { - if (*key != test(table->record[0][key_part->null_offset] & - key_part->null_bit)) + if (*key != MY_TEST(table->record[0][key_part->null_offset] & + key_part->null_bit)) return 1; if (*key) continue; @@ -438,7 +438,7 @@ void key_unpack(String *to, TABLE *table, KEY *key) } } 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; |