summaryrefslogtreecommitdiff
path: root/mysys/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'mysys/string.c')
-rw-r--r--mysys/string.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/mysys/string.c b/mysys/string.c
index 7c56b95af25..b346393d91e 100644
--- a/mysys/string.c
+++ b/mysys/string.c
@@ -36,7 +36,8 @@ my_bool init_dynamic_string(DYNAMIC_STRING *str, const char *init_str,
if (!init_alloc)
init_alloc=alloc_increment;
- if (!(str->str=(char*) my_malloc(init_alloc,MYF(MY_WME))))
+ if (!(str->str=(char*) my_malloc(key_memory_DYNAMIC_STRING,
+ init_alloc, MYF(MY_WME))))
DBUG_RETURN(TRUE);
str->length=length-1;
if (init_str)
@@ -58,7 +59,8 @@ my_bool dynstr_set(DYNAMIC_STRING *str, const char *init_str)
str->alloc_increment;
if (!str->max_length)
str->max_length=str->alloc_increment;
- if (!(str->str=(char*) my_realloc(str->str,str->max_length,MYF(MY_WME))))
+ if (!(str->str=(char*) my_realloc(key_memory_DYNAMIC_STRING,
+ str->str, str->max_length, MYF(MY_WME))))
DBUG_RETURN(TRUE);
}
if (init_str)
@@ -81,7 +83,8 @@ my_bool dynstr_realloc(DYNAMIC_STRING *str, size_t additional_size)
{
str->max_length=((str->length + additional_size+str->alloc_increment-1)/
str->alloc_increment)*str->alloc_increment;
- if (!(str->str=(char*) my_realloc(str->str,str->max_length,MYF(MY_WME))))
+ if (!(str->str=(char*) my_realloc(key_memory_DYNAMIC_STRING, str->str,
+ str->max_length, MYF(MY_WME))))
DBUG_RETURN(TRUE);
}
DBUG_RETURN(FALSE);
@@ -104,7 +107,8 @@ my_bool dynstr_append_mem(DYNAMIC_STRING *str, const char *append,
size_t new_length=(str->length+length+str->alloc_increment)/
str->alloc_increment;
new_length*=str->alloc_increment;
- if (!(new_ptr=(char*) my_realloc(str->str,new_length,MYF(MY_WME))))
+ if (!(new_ptr=(char*) my_realloc(key_memory_DYNAMIC_STRING, str->str,
+ new_length, MYF(MY_WME))))
DBUG_RETURN(TRUE);
str->str=new_ptr;
str->max_length=new_length;