When there is conjunction of conds, the substitute_for_best_equal_field()
will call the eliminate_item_equal() function in loop to build final
expression. But if eliminate_item_equal() finds that some cond will always
evaluate to 0, then that cond will be substituted by Item_int with value ==
0. In this case on the next iteration eliminate_item_equal() will get that
Item_int and treat it as Item_cond. This is leads to memory corruption and
server crash on cleanup phase.
To the eliminate_item_equal() function was added DBUG_ASSERT for checking
that all items treaten as Item_cond are really Item_cond.
The substitute_for_best_equal_field() now checks that if
eliminate_item_equal() returns Item_int and it's value is 0 then this
value is returned as the result of whole conjunction.
mysql-test/t/subselect.test:
Added test for bug#17366: Unchecked Item_int results in server crash
mysql-test/r/subselect.result:
Added test for bug#17366: Unchecked Item_int results in server crash
sql/sql_select.cc:
Fixed bug#17366: Unchecked Item_int results in server crash
To the eliminate_item_equal() function was added DBUG_ASSERT for checking
that all items treaten as Item_cond are really Item_cond.
The substitute_for_best_equal_field() now checks that if
eliminate_item_equal() returns something other than Item_cond and if it is
then this value is returned as the result of whole conjunction.
Revise option description. And let's put it in the proper
lexical order within the option list.
sql/mysqld.cc:
Revise option description. And let's put it in the proper
lexical order within the option list.
Small change to enable sending of mails from Windows bk clones
BitKeeper/triggers/post-commit:
Small change to enable sending of mails from Windows bk clones
sql/log_event.cc:
Fix Windows compile errors.
storage/innobase/btr/btr0sea.c:
Fix AIX compile error (declarations must come before code in traditional C).
sql/sql_class.h:
Fix HPUX compile problem (HP compiler bug).
Local class of member in derived class has no access to protected members,
so make the class global and a friend.
sql/sql_insert.cc:
Fix HPUX compile problem (HP compiler bug).
Local class of member in derived class has no access to protected members,
so make the class global and a friend.
- detect the need for row-based binlogging not at execution stage but earlier at parsing stage; needed for example for CREATE TABLE SELECT UUID().
- more tests of this mixed mode.
mysql-test/r/rpl_switch_stm_row_mixed.result:
result update
mysql-test/t/rpl_switch_stm_row_mixed.test:
testing more scenarios for the mixed replication mode.
Added support for manual testing of UDFs vs the mixed mode (behind a variable in the test).
Changing old file names to better ones.
sql/item_create.cc:
at parse time, when we see a UUID(), put up a flag in LEX to say this binlogs properly only with row-based binlogging.
sql/item_func.cc:
it's not perfect to put up the flag at this execution stage, better do it at parse stage.
sql/item_strfunc.cc:
it's not perfect to put up the flag at this execution stage, better do it at parse stage
sql/set_var.cc:
this assertion is wrong, this piece of code can happen in RBR mode too.
sql/sql_lex.cc:
when we reinitialize the LEX members before every query, we have to reinitialize the new flag
sql/sql_lex.h:
A new flag, set at parsing stage, which tells if some items seen during parsing stage require row-based replication to binlog/replicate correctly
when this statement is later executed.
It has to be in LEX and not directly in THD, for this to work in prepared statements.
sql/sql_parse.cc:
Parsing stage happened at some time in the past and set up the flag in LEX, now that we execute the statement we actually turn on row-based binlogging
if the thread's binlog format is "mixed". We then turn it off when leaving mysql_execute_command().
Some cleanup code was not executed if leaving mysql_execute_command() at the "error" label, fixing this. A better fix than the "goto end" would be
to modify each "goto error" to "res=1; goto end" but it required changing many lines which I don't want to do now ("make smallest possible patch").
sql/sql_yacc.yy:
When at parsing stage we see a UDF we put up a flag to say that row-based binlogging is preferred.
into mysql.com:/home/jimw/my/mysql-5.1-clean
sql/sql_partition.cc:
Auto merged
mysql-test/r/partition.result:
e
Resolve conflict
mysql-test/t/partition.test:
Resolve conflict
Bug # 17894 - Comparison with "less than" operator fails with range partition
The problem here was that on queries such as < 3, the range given is NULL < n < 3.
The null part works correctly where the null value is stored in rec[0] and the
field is marked as being null. However, when the 3 is processed, the 3 is places
on rec[0] but the null flag is left uncleared.
partition_range.result:
Results block for bug #17894
partition_range.test:
Test block for bug #17894
partition_list.result:
Results block for bug #17173
partition_list.test:
Test block for bug #17173
opt_range.cc:
call set_notnull to clear any null flag that may have been set
sql/opt_range.cc:
call set_notnull to clear any null flag that may have been set
mysql-test/t/partition_list.test:
Test block for bug #17173
mysql-test/r/partition_list.result:
Results block for bug #17173
mysql-test/t/partition_range.test:
Test block for bug #17894
mysql-test/r/partition_range.result:
Results block for bug #17894
ndb crash if trigger record get to big, fix incorrect max size of trigger record
ndb/src/kernel/blocks/backup/Backup.cpp:
Increase size of max trigger record
ndb crash if trigger record get to big, fix incorrect max size of trigger record
ndb/src/kernel/blocks/backup/Backup.cpp:
Increase size of max trigger record
When doing an ALTER TABLE on a table using partitioning, force the table
definition to get reloaded, since it may become invalid whenever the ALTER
TABLE fails (even for an ALTER TABLE without specific partitioning changes).
mysql-test/r/partition.result:
New results
mysql-test/t/partition.test:
New regression test
sql/sql_partition.cc:
Always force table to get reloaded when we ALTER a
partitioned table
incorrect handling of varsize primary key and charsets in tup-scan
storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp:
put tracenr log in signal log instead...as out file gets very big...
storage/ndb/src/kernel/blocks/dbtup/DbtupScan.cpp:
PK needs to be normalized before computing hashvalue, otherwise lock-req will not find row,
causing assertion in debug build, and inconsistency in release
put nrtrace in out file instead (debug compiled..)
storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp:
put nrtrace in out file instead (debug compiled..)
Fixed problem where taocrypt was defined too early in the process
win/cmakefiles/base:
Fixed problem where taocrypt was defined too early in the process
mysql-test/mysql-test-run.pl:
Take a snapshot of the data dirs just after all db's have been installed and usedthat snasphot to restore the db(s) to a known state after a test case has failed.
Thus avoiding subsequent test cases to fail because of previous test failures.