Backport into build-201003230706-5.1.43sp1
Backport into build-201003230706-5.1.43sp1

> ------------------------------------------------------------
> revno: 3315.1.1
> revision-id: mattias.jonsson@sun.com-20100118164918-afjah8vmey4ya4ox
> parent: joro@sun.com-20100115090646-0g4tjrmqf20axlpv
> committer: Mattias Jonsson <mattias.jonsson@sun.com>
> branch nick: b47343-51-bt
> timestamp: Mon 2010-01-18 17:49:18 +0100
> message:
>   Bug#47343: InnoDB fails to clean-up after lock wait timeout on
>              REORGANIZE PARTITION
>   
>   There were several problems which lead to this this,
>   all related to bad error handling.
>   
>   1) There was several bugs preventing the ddl-log to be used for
>      cleaning up created files on error.
>   
>   2) The error handling after the copy partition rows did not close
>      and unlock the tables, resulting in deletion of partitions
>      which were in use, which lead InnoDB to put the partition to
>      drop in a background queue.

> ------------------------------------------------------------
> revno: 3325
> revision-id: mattias.jonsson@sun.com-20100119160251-0xvcgzw0y08xwk6r
> parent: joro@sun.com-20091223151122-ada73up1yydh0emt
> committer: Mattias Jonsson <mattias.jonsson@sun.com>
> branch nick: topush-51-bugteam
> timestamp: Tue 2010-01-19 17:02:51 +0100
> message:
>   post-push patch for bug#47343.
>   
>   Missing ha_rnd_end in copy_partitions, found due to a
>   DBUG_ASSERT in mysql-pe

ollie314/server,davidl-zend/zenddbi,flynn1973/mariadb-aix,ollie314/server,flynn1973/mariadb-aix,ollie314/server,flynn1973/mariadb-aix,davidl-zend/zenddbi,ollie314/server,natsys/mariadb_10.2,davidl-zend/zenddbi,natsys/mariadb_10.2,davidl-zend/zenddbi,ollie314/server,natsys/mariadb_10.2,natsys/mariadb_10.2,ollie314/server,ollie314/server,flynn1973/mariadb-aix,natsys/mariadb_10.2,davidl-zend/zenddbi,ollie314/server,flynn1973/mariadb-aix,ollie314/server,davidl-zend/zenddbi,flynn1973/mariadb-aix,ollie314/server,slanterns/server,natsys/mariadb_10.2,davidl-zend/zenddbi,natsys/mariadb_10.2,natsys/mariadb_10.2,natsys/mariadb_10.2,natsys/mariadb_10.2,flynn1973/mariadb-aix,davidl-zend/zenddbi,flynn1973/mariadb-aix,flynn1973/mariadb-aix,flynn1973/mariadb-aix,davidl-zend/zenddbi,ollie314/server,davidl-zend/zenddbi,natsys/mariadb_10.2,flynn1973/mariadb-aix,davidl-zend/zenddbi