1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

Added checking of return value from my_once_alloc() in charset

Added checking of return value from malloc() in reg_init()


client/mysqltest.c:
  Added comment
dbug/dbug.c:
  Removed not needed test
mysys/charset.c:
  Added checking of return value from my_once_alloc()
regex/reginit.c:
  Abort if out of memory in reg_init() (unlikely)
sql/item_strfunc.cc:
  Added comment
This commit is contained in:
unknown
2003-12-10 00:00:20 +02:00
parent 4e85bf326e
commit 6b97c26a29
5 changed files with 54 additions and 15 deletions

View File

@ -2302,6 +2302,7 @@ static VAR* var_init(VAR* v, const char* name, int name_len, const char* val,
if (!(tmp_var->str_val = my_malloc(val_alloc_len+1, MYF(MY_WME))))
die("Out of memory");
/* 'name' may be NULL here, but in this case name_len is 0 */
memcpy(tmp_var->name, name, name_len);
if (val)
{