summaryrefslogtreecommitdiff
path: root/storage/innobase
diff options
context:
space:
mode:
authorVasil Dimov <vasil.dimov@oracle.com>2012-10-09 16:41:13 +0300
committerVasil Dimov <vasil.dimov@oracle.com>2012-10-09 16:41:13 +0300
commit61bd7d0ce988328cf24d0d9ea7666fcf7597b682 (patch)
treef9f07041fe0a468f88515ca2ca850fa6a6a085f4 /storage/innobase
parent5427d33e6248caa4e6a2b92c9ab9317fadcb5c2f (diff)
parent4cefe863aee8430a09e74a52feef0eb9ea4fae9b (diff)
downloadmariadb-git-61bd7d0ce988328cf24d0d9ea7666fcf7597b682.tar.gz
Merge mysql-5.1 -> mysql-5.5
Diffstat (limited to 'storage/innobase')
-rw-r--r--storage/innobase/os/os0file.c13
-rw-r--r--storage/innobase/row/row0mysql.c5
2 files changed, 17 insertions, 1 deletions
diff --git a/storage/innobase/os/os0file.c b/storage/innobase/os/os0file.c
index 1c50e903965..db777f024fd 100644
--- a/storage/innobase/os/os0file.c
+++ b/storage/innobase/os/os0file.c
@@ -1397,6 +1397,13 @@ os_file_create_func(
DWORD create_flag;
DWORD attributes;
ibool retry;
+
+ DBUG_EXECUTE_IF(
+ "ib_create_table_fail_disk_full",
+ *success = FALSE;
+ SetLastError(ERROR_DISK_FULL);
+ return((os_file_t) -1);
+ );
try_again:
ut_a(name);
@@ -1512,6 +1519,12 @@ try_again:
ibool retry;
const char* mode_str = NULL;
+ DBUG_EXECUTE_IF(
+ "ib_create_table_fail_disk_full",
+ *success = FALSE;
+ errno = ENOSPC;
+ return((os_file_t) -1);
+ );
try_again:
ut_a(name);
diff --git a/storage/innobase/row/row0mysql.c b/storage/innobase/row/row0mysql.c
index 20e8c13ea70..7e1d18d41b6 100644
--- a/storage/innobase/row/row0mysql.c
+++ b/storage/innobase/row/row0mysql.c
@@ -1855,7 +1855,8 @@ Creates a table for MySQL. If the name of the table ends in
one of "innodb_monitor", "innodb_lock_monitor", "innodb_tablespace_monitor",
"innodb_table_monitor", then this will also start the printing of monitor
output by the master thread. If the table name ends in "innodb_mem_validate",
-InnoDB will try to invoke mem_validate().
+InnoDB will try to invoke mem_validate(). On failure the transaction will
+be rolled back and the 'table' object will be freed.
@return error code or DB_SUCCESS */
UNIV_INTERN
int
@@ -1993,6 +1994,8 @@ err_exit:
row_drop_table_for_mysql(table->name, trx, FALSE);
trx_commit_for_mysql(trx);
+ } else {
+ dict_mem_table_free(table);
}
break;