Hi Libing,
Thank your for the review.
I've done what you requested and committed a new patch.
Before pushing the changes I will see if the runtime is ok and also
Innodb team.
Cheers.
Libing Song wrote:
> Hi Alfranio,
> Patch approved.
> Please find my comments below, there are some typos.
>
> On Mon, 2010-04-19 at 09:05 +0000, Alfranio Correia wrote:
>> #At
> file:///home/acorreia/workspace.sun/repository.mysql/bzrwork/bug-50479/mysql-5.1-rep%2B2/
> based on revid:sven.sandberg@stripped
>>
>
>> +
>> +--echo
> ################################################################################
>> +--echo # Verifies if ER_BINLOG_STMT_MODE_AND_ROW_ENGINE happens by setting the
> binlog
>> +--echo # format to STATEMENT and the transaction isolation level to READ
> COMMITTED as
>> +--echo # such changes force Innodb to accept changes in the row format.
>> +--echo #
>> +--echo # When CREATE TABLE, ALTER TABLE, CREATE INDEX and CREATE TRIGGER are
> executed
>> +--echo # any error should be triggered.
>> +--echo #
>> +--echo # In contrats, CREATE TABLE ... SELECT should trigger the following
> error:
> typo: s/contrats/contrast/
>
done.
>> +
>> +--echo
> ################################################################################
>> +--echo # Verifies if ER_BINLOG_ROW_MODE_AND_STMT_ENGINE happens by setting the
> binlog
>> +--echo # format to ROW and using a engine, i.e. EXAMPLE, that only supports
> STATEMENT.
>> +--echo #
>> +--echo # When CREATE TABLE, ALTER TABLE, CREATE INDEX and CREATE TRIGGER are
> executed
>> +--echo # the error ER_BINLOG_ROW_MODE_AND_STMT_ENGINE is not triggered. Note
> that other
>> +--echo # errors are triggered due to restrictions in the engine.
>> +--echo #
>> +--echo # In contrats, CREATE TABLE ... SELECT should trigger the following
> error:
> typo: s/contrats/contrast/
done.
>
>> === modified file 'storage/innobase/handler/ha_innodb.cc'
>> --- a/storage/innobase/handler/ha_innodb.cc 2010-03-03 14:43:35 +0000
>> +++ b/storage/innobase/handler/ha_innodb.cc 2010-04-19 09:05:21 +0000
>> @@ -7165,7 +7165,9 @@ ha_innobase::external_lock(
>> if (lock_type == F_WRLCK &&
>> !(table_flags() & HA_BINLOG_STMT_CAPABLE) &&
>> thd_binlog_format(thd) == BINLOG_FORMAT_STMT &&
>> - thd_binlog_filter_ok(thd))
>> + thd_binlog_filter_ok(thd)
>> + && thd_generates_rows(thd)
> it might be better to put '&&' at the end of last line.
>
>
>
>
done.