1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

MDEV-21765 Possibly inconsistent behavior of BIT_xx functions with INET6 field

Disallow BIT_AND(), BIT_OR(), BIT_XOR() for data types GEOMETRY and INET6,
as they cannot return any useful integer values.
This commit is contained in:
Alexander Barkov
2020-06-09 12:54:04 +04:00
parent 01e8459d93
commit 76cb2f9dd6
5 changed files with 52 additions and 0 deletions

View File

@@ -1208,6 +1208,8 @@ public:
const Type_handler *type_handler() const { return &type_handler_ulonglong; }
bool fix_length_and_dec()
{
if (args[0]->check_type_can_return_int(func_name()))
return true;
decimals= 0; max_length=21; unsigned_flag= 1; maybe_null= null_value= 0;
return FALSE;
}