core: Remove incorrect usage of attribute_malloc.

GCC documentation states that when __attribute__((malloc)) is used it
should not return storage which contains any valid pointers.  It
specifically mentions that realloc functions should not have the malloc
attribute, but this also means that complex initializers which could
contain initialized pointers should not use this attribute.

Change-Id: If507f33ffb3ca3b83b702196eb0e8215d27fc7d2
This commit is contained in:
Corey Farrell
2018-03-13 17:37:12 -04:00
parent 0a402dc851
commit dc738b145f
6 changed files with 7 additions and 7 deletions

View File

@@ -816,7 +816,7 @@ void * attribute_malloc _ast_calloc(size_t num, size_t len, const char *file, in
_ast_realloc((p), (len), __FILE__, __LINE__, __PRETTY_FUNCTION__)
AST_INLINE_API(
void * attribute_malloc _ast_realloc(void *p, size_t len, const char *file, int lineno, const char *func),
void *_ast_realloc(void *p, size_t len, const char *file, int lineno, const char *func),
{
void *newp;