summaryrefslogtreecommitdiff
path: root/storage/heap/ha_heap.cc
diff options
context:
space:
mode:
Diffstat (limited to 'storage/heap/ha_heap.cc')
-rw-r--r--storage/heap/ha_heap.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/storage/heap/ha_heap.cc b/storage/heap/ha_heap.cc
index 08c4b226e22..162943cca17 100644
--- a/storage/heap/ha_heap.cc
+++ b/storage/heap/ha_heap.cc
@@ -91,6 +91,15 @@ ha_heap::ha_heap(handlerton *hton, TABLE_SHARE *table_arg)
int ha_heap::open(const char *name, int mode, uint test_if_locked)
{
+ if (table->s->reclength < sizeof (char*))
+ {
+ MEM_UNDEFINED(table->s->default_values + table->s->reclength,
+ sizeof(char*) - table->s->reclength);
+ table->s->reclength= sizeof(char*);
+ MEM_UNDEFINED(table->record[0], table->s->reclength);
+ MEM_UNDEFINED(table->record[1], table->s->reclength);
+ }
+
internal_table= MY_TEST(test_if_locked & HA_OPEN_INTERNAL_TABLE);
if (internal_table || (!(file= heap_open(name, mode)) && my_errno == ENOENT))
{