Use malloc/strdup instead of Alloc.

This commit is contained in:
Reece H. Dunn
2016-01-18 20:34:59 +00:00
parent 325014da42
commit bbd981efb8
5 changed files with 7 additions and 21 deletions
-12
View File
@@ -251,18 +251,6 @@ int GetFileLength(const char *filename)
return statbuf.st_size;
}
#pragma GCC visibility pop
char *Alloc(int size)
{
char *p;
if ((p = (char *)malloc(size)) == NULL)
fprintf(stderr, "Can't allocate memory\n"); // I was told that size+1 fixes a crash on 64-bit systems
return p;
}
#pragma GCC visibility push(default)
ESPEAK_NG_API void espeak_ng_InitializePath(const char *path)
{
if (path != NULL) {