Fix for LP#697610 ha_index_prev(uchar*): Assertion `inited==INDEX' failed with HANDLER + InnoDB in maria-5.3

mysql-test/suite/handler/innodb.result:
  Added test case
mysql-test/suite/handler/innodb.test:
  Added test case
sql/handler.h:
  Move setting/resetting of active_index to ha_index_init()/ha_index_end() to simplify handler functions index_init()/index_end()
  Fixed that get_index() returns MAX_KEY if index is not inited (this fixed LP#697610)
storage/federated/ha_federated.cc:
  Settting of active_index is not needed anymore
storage/maria/ma_pagecache.c:
  Added error message if we have too little memory for Maria page cache
This commit is contained in:
Michael Widenius 2011-01-12 15:41:39 +02:00
commit 213321206e
5 changed files with 37 additions and 7 deletions

View file

@ -759,6 +759,8 @@ ulong init_pagecache(PAGECACHE *pagecache, size_t use_mem,
{
if (blocks < 8)
{
my_message(ENOMEM, "Not enough memory to allocate 8 pagecache pages",
MYF(0));
my_errno= ENOMEM;
goto err;
}