Commit d5c1475d authored by marko@hundin.mysql.fi's avatar marko@hundin.mysql.fi

dict0load.c:

  dict_load_table(): Refuse to open ROW_FORMAT=COMPACT tables
  of MySQL 5.0.3 and later.
parent 5d865045
...@@ -639,7 +639,7 @@ dict_load_table( ...@@ -639,7 +639,7 @@ dict_load_table(
/* Check if the table name in record is the searched one */ /* Check if the table name in record is the searched one */
if (len != ut_strlen(name) || ut_memcmp(name, field, len) != 0) { if (len != ut_strlen(name) || ut_memcmp(name, field, len) != 0) {
err_exit:
btr_pcur_close(&pcur); btr_pcur_close(&pcur);
mtr_commit(&mtr); mtr_commit(&mtr);
mem_heap_free(heap); mem_heap_free(heap);
...@@ -662,6 +662,13 @@ dict_load_table( ...@@ -662,6 +662,13 @@ dict_load_table(
field = rec_get_nth_field(rec, 4, &len); field = rec_get_nth_field(rec, 4, &len);
n_cols = mach_read_from_4(field); n_cols = mach_read_from_4(field);
if (n_cols & 0x80000000UL) {
ut_print_timestamp(stderr);
fprintf(stderr,
" InnoDB: table %s is in the new compact format\n"
"InnoDB: of MySQL 5.0.3 or later\n", name);
goto err_exit;
}
table = dict_mem_table_create(name, space, n_cols); table = dict_mem_table_create(name, space, n_cols);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment