зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1498458 - Add a test for OOM on failure to allocate ArrayBuffer contents that won't fit in a typed array's inline storage. r=nbp
--HG-- extra : rebase_source : 5ef813c93a05b6fe45477179fa1d91e0d478c295
This commit is contained in:
Родитель
def84d6ecb
Коммит
52f3ecf834
|
@ -0,0 +1,15 @@
|
|||
// |jit-test| skip-if: !('oomTest' in this)
|
||||
|
||||
// Resolve ArrayBuffer before OOM-testing, so OOM-testing runs less code and is
|
||||
// less fragile.
|
||||
var AB = ArrayBuffer;
|
||||
|
||||
function f()
|
||||
{
|
||||
return new AB(256);
|
||||
}
|
||||
|
||||
// Create |f|'s script before OOM-testing for the same reason.
|
||||
f();
|
||||
|
||||
oomTest(f);
|
Загрузка…
Ссылка в новой задаче