зеркало из https://github.com/mozilla/gecko-dev.git
Bug 735036 - Check for OOM in debug only method. r=luke
This commit is contained in:
Родитель
fe5797c0c4
Коммит
a54448c56d
|
@ -384,7 +384,7 @@ class HashTable : private AllocPolicy
|
|||
mutationCount(0)
|
||||
{}
|
||||
|
||||
bool init(uint32_t length)
|
||||
MOZ_WARN_UNUSED_RESULT bool init(uint32_t length)
|
||||
{
|
||||
/* Make sure that init isn't called twice. */
|
||||
JS_ASSERT(table == NULL);
|
||||
|
|
|
@ -4193,7 +4193,8 @@ StartVerifyBarriers(JSRuntime *rt)
|
|||
trc->edgeptr = (char *)trc->root;
|
||||
trc->term = trc->edgeptr + size;
|
||||
|
||||
trc->nodemap.init();
|
||||
if (!trc->nodemap.init())
|
||||
return;
|
||||
|
||||
/* Create the root node. */
|
||||
trc->curnode = MakeNode(trc, NULL, JSGCTraceKind(0));
|
||||
|
|
Загрузка…
Ссылка в новой задаче