зеркало из https://github.com/mozilla/gecko-dev.git
Remove the extern Flush_Allocate, and replace call with a malloc.
This commit is contained in:
Родитель
3ef9587b99
Коммит
18e315daff
|
@ -24,7 +24,6 @@
|
||||||
|
|
||||||
#include "macstdlibextras.h"
|
#include "macstdlibextras.h"
|
||||||
|
|
||||||
extern void* Flush_Allocate(size_t, Boolean);
|
|
||||||
|
|
||||||
int strcmpcore(const char*, const char*, int, int);
|
int strcmpcore(const char*, const char*, int, int);
|
||||||
|
|
||||||
|
@ -123,7 +122,7 @@ char *strdup(const char *source)
|
||||||
|
|
||||||
/* since this gets freed by an XP_FREE, it must do an XP_ALLOC */
|
/* since this gets freed by an XP_FREE, it must do an XP_ALLOC */
|
||||||
/* newAllocation = (char *)XP_ALLOC(stringLength); */
|
/* newAllocation = (char *)XP_ALLOC(stringLength); */
|
||||||
newAllocation = (char *)Flush_Allocate(stringLength, 0);
|
newAllocation = (char *)malloc(stringLength);
|
||||||
if (newAllocation == NULL)
|
if (newAllocation == NULL)
|
||||||
return NULL;
|
return NULL;
|
||||||
BlockMoveData(source, newAllocation, stringLength);
|
BlockMoveData(source, newAllocation, stringLength);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче