mirror of
https://github.com/MariaDB/server.git
synced 2025-01-26 00:34:18 +01:00
In allocate_dynamic() fixed return value on error.
The previous value probably was copied from alloc_dynamic() where it means number of elements.
This commit is contained in:
parent
9a25f2a5bb
commit
95fdfb733d
1 changed files with 1 additions and 1 deletions
|
@ -248,7 +248,7 @@ my_bool allocate_dynamic(DYNAMIC_ARRAY *array, uint max_elements)
|
|||
if (!(new_ptr= (uchar *) my_malloc(array->m_psi_key, size *
|
||||
array->size_of_element,
|
||||
MYF(array->malloc_flags | MY_WME))))
|
||||
DBUG_RETURN(0);
|
||||
DBUG_RETURN(TRUE);
|
||||
memcpy(new_ptr, array->buffer,
|
||||
array->elements * array->size_of_element);
|
||||
array->malloc_flags&= ~MY_INIT_BUFFER_USED;
|
||||
|
|
Loading…
Add table
Reference in a new issue