Changeset 271239 in webkit
- Timestamp:
- Jan 7, 2021, 9:23:23 AM (6 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 3 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/fast/files/blob-stream-crash-expected.txt (added)
-
LayoutTests/fast/files/blob-stream-crash.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/fileapi/Blob.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r271235 r271239 1 2021-01-07 Alex Christensen <achristensen@webkit.org> 2 3 Null check global object in Blob::stream 4 https://bugs.webkit.org/show_bug.cgi?id=220393 5 <rdar://problem/71626701> 6 7 Reviewed by Chris Dumez. 8 9 * fast/files/blob-stream-crash-expected.txt: Added. 10 * fast/files/blob-stream-crash.html: Added. 11 1 12 2021-01-07 Lauro Moura <lmoura@igalia.com> 2 13 -
trunk/Source/WebCore/ChangeLog
r271235 r271239 1 2021-01-07 Alex Christensen <achristensen@webkit.org> 2 3 Null check global object in Blob::stream 4 https://bugs.webkit.org/show_bug.cgi?id=220393 5 <rdar://problem/71626701> 6 7 Reviewed by Chris Dumez. 8 9 Sometimes during a frame teardown we could dereference null. 10 Attached a test that hit it about 10% of the time for me in WebKitTestRunner before this change. 11 12 Test: fast/files/blob-stream-crash.html 13 14 * fileapi/Blob.cpp: 15 (WebCore::Blob::stream): 16 1 17 2021-01-07 Lauro Moura <lmoura@igalia.com> 2 18 -
trunk/Source/WebCore/fileapi/Blob.cpp
r268700 r271239 278 278 }; 279 279 280 return ReadableStream::create(*scriptExecutionContext.globalObject(), adoptRef(*new BlobStreamSource(scriptExecutionContext, *this))); 280 auto* globalObject = scriptExecutionContext.globalObject(); 281 if (!globalObject) 282 return Exception { InvalidStateError }; 283 return ReadableStream::create(*globalObject, adoptRef(*new BlobStreamSource(scriptExecutionContext, *this))); 281 284 } 282 285
Note:
See TracChangeset
for help on using the changeset viewer.