Index: LayoutTests/fast/filesystem/script-tests/read-directory.js |
diff --git a/LayoutTests/fast/filesystem/script-tests/read-directory.js b/LayoutTests/fast/filesystem/script-tests/read-directory.js |
index e88ff313977bd79e4ce09dc9425736e360ef5071..313db53888a9cb7d51fd62fd88931228c23d2983 100644 |
--- a/LayoutTests/fast/filesystem/script-tests/read-directory.js |
+++ b/LayoutTests/fast/filesystem/script-tests/read-directory.js |
@@ -42,12 +42,13 @@ function verifyTestResult() |
} |
} |
-function entriesCallback(entries) |
+var entries; |
+function entriesCallback(_entries) |
{ |
entriesCallbackCount++; |
- |
- for (var i = 0; i < entries.length; ++i) |
- resultEntries.push(entries[i]); |
+ entries = _entries; |
+ shouldBe("entries.__proto__", "Array.prototype"); |
+ resultEntries.push.apply(resultEntries, entries); |
if (entries.length) { |
readEntriesCount++; |