diff options
Diffstat (limited to 'sql/unireg.cc')
-rw-r--r-- | sql/unireg.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sql/unireg.cc b/sql/unireg.cc index edcfe9eb934..20d101be1a3 100644 --- a/sql/unireg.cc +++ b/sql/unireg.cc @@ -282,7 +282,7 @@ bool mysql_create_frm(THD *thd, const char *file_name, } key_buff_length= uint4korr(fileinfo+47); - keybuff=(uchar*) my_malloc(key_buff_length, MYF(0)); + keybuff=(uchar*) my_malloc(key_buff_length, MYF(MY_THREAD_SPECIFIC)); key_info_length= pack_keys(keybuff, keys, key_info, data_offset); /* @@ -534,7 +534,7 @@ static uchar *pack_screens(List<Create_field> &create_fields, while ((field=it++)) length+=(uint) strlen(field->field_name)+1+TE_INFO_LENGTH+cols/2; - if (!(info=(uchar*) my_malloc(length,MYF(MY_WME)))) + if (!(info=(uchar*) my_malloc(length,MYF(MY_WME | MY_THREAD_SPECIFIC)))) DBUG_RETURN(0); start_screen=0; @@ -1108,7 +1108,9 @@ static bool make_empty_rec(THD *thd, File file,enum legacy_db_type table_type, bzero((char*) &share, sizeof(share)); table.s= &share; - if (!(buff=(uchar*) my_malloc((size_t) reclength,MYF(MY_WME | MY_ZEROFILL)))) + if (!(buff=(uchar*) my_malloc((size_t) reclength, + MYF(MY_WME | MY_ZEROFILL | + MY_THREAD_SPECIFIC)))) { DBUG_RETURN(1); } |