mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
Merge remote-tracking branch 'origin/5.5' into 10.1
This commit is contained in:
@@ -20,6 +20,19 @@ COALESCE(@a)
|
||||
1
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# MDEV-21065 UNIQUE constraint causes a query with string comparison to omit a row in the result set
|
||||
#
|
||||
CREATE TABLE t1 (c0 INT UNIQUE);
|
||||
INSERT INTO t1 VALUES (NULL), (NULL), (NULL), (NULL), (1), (0);
|
||||
SELECT * FROM t1 WHERE c0 < '\n2';
|
||||
c0
|
||||
0
|
||||
1
|
||||
DROP TABLE t1;
|
||||
SELECT CAST('\n2' AS INT);
|
||||
CAST('\n2' AS INT)
|
||||
2
|
||||
#
|
||||
# End of 5.5 tests
|
||||
#
|
||||
#
|
||||
|
||||
@@ -14,6 +14,18 @@ SELECT COALESCE(@a:=1) FROM t1 ORDER BY STRCMP(STDDEV_SAMP(a), 'bar');
|
||||
SELECT COALESCE(@a) FROM t1 ORDER BY STRCMP(STDDEV_SAMP(a), 'bar');
|
||||
DROP TABLE t1;
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-21065 UNIQUE constraint causes a query with string comparison to omit a row in the result set
|
||||
--echo #
|
||||
|
||||
CREATE TABLE t1 (c0 INT UNIQUE);
|
||||
INSERT INTO t1 VALUES (NULL), (NULL), (NULL), (NULL), (1), (0);
|
||||
SELECT * FROM t1 WHERE c0 < '\n2';
|
||||
DROP TABLE t1;
|
||||
|
||||
SELECT CAST('\n2' AS INT);
|
||||
|
||||
|
||||
--echo #
|
||||
--echo # End of 5.5 tests
|
||||
--echo #
|
||||
|
||||
@@ -49,6 +49,12 @@ MY_CHECK_AND_SET_COMPILER_FLAG("-Wno-vla" DEBUG)
|
||||
MY_CHECK_AND_SET_COMPILER_FLAG("-Wno-implicit-fallthrough")
|
||||
MY_CHECK_AND_SET_COMPILER_FLAG("-Wno-cpp" DEBUG)
|
||||
|
||||
CHECK_C_COMPILER_FLAG("-Wno-address-of-packed-member" HAVE_NO_ADDRESS_PACKED)
|
||||
IF(HAVE_NO_ADDRESS_PACKED)
|
||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-address-of-packed-member")
|
||||
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-address-of-packed-member")
|
||||
ENDIF()
|
||||
|
||||
############################################
|
||||
SET(TOKUDB_DEB_FILES "usr/lib/mysql/plugin/ha_tokudb.so\netc/mysql/conf.d/tokudb.cnf\nusr/bin/tokuftdump" PARENT_SCOPE)
|
||||
MARK_AS_ADVANCED(BUILDNAME)
|
||||
|
||||
@@ -1494,7 +1494,8 @@ my_strntoull10rnd_8bit(CHARSET_INFO *cs __attribute__((unused)),
|
||||
int shift= 0, digits= 0, negative, addon;
|
||||
|
||||
/* Skip leading spaces and tabs */
|
||||
for ( ; str < end && (*str == ' ' || *str == '\t') ; str++);
|
||||
for ( ; str < end && my_isspace(&my_charset_latin1, *str) ; )
|
||||
str++;
|
||||
|
||||
if (str >= end)
|
||||
goto ret_edom;
|
||||
|
||||
@@ -98,18 +98,25 @@ longlong my_strtoll10(const char *nptr, char **endptr, int *error)
|
||||
if (endptr)
|
||||
{
|
||||
end= *endptr;
|
||||
while (s != end && (*s == ' ' || *s == '\t'))
|
||||
/* Skip leading spaces */
|
||||
for ( ; s < end && my_isspace(&my_charset_latin1, *s) ; )
|
||||
s++;
|
||||
|
||||
if (s == end)
|
||||
goto no_conv;
|
||||
}
|
||||
else
|
||||
{
|
||||
endptr= &dummy; /* Easier end test */
|
||||
while (*s == ' ' || *s == '\t')
|
||||
s++;
|
||||
if (!*s)
|
||||
goto no_conv;
|
||||
/* Skip leading spaces */
|
||||
for ( ; ; s++)
|
||||
{
|
||||
if (!*s)
|
||||
goto no_conv;
|
||||
if (!my_isspace(&my_charset_latin1, *s))
|
||||
break;
|
||||
}
|
||||
|
||||
/* This number must be big to guard against a lot of pre-zeros */
|
||||
end= s+65535; /* Can't be longer than this */
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user