Bug 184161

Summary: ASSERTION FAILED: ASSERT(!containsImage || MIMETypeRegistry::isSupportedImageResourceMIMEType([resource MIMEType])) in -[NSPasteboard(WebExtras) _web_writePromisedRTFDFromArchive:containsImage:]
Product: WebKit Reporter: Daniel Bates <dbates>
Component: WebKit Misc.Assignee: Daniel Bates <dbates>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, esprehn+autocc, ews-watchlist, kangil.han, mitz, pvollan, rniwa, thorton, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Mac   
OS: All   
See Also: https://bugs.webkit.org/show_bug.cgi?id=178502
https://bugs.webkit.org/show_bug.cgi?id=178618
https://bugs.webkit.org/show_bug.cgi?id=133944
Attachments:
Description Flags
TestCase
none
Patch and manual test
none
Patch and manual test
none
Patch and manual test mitz: review+

Daniel Bates
Reported 2018-03-29 15:26:40 PDT
Steps to reproduce using a debug build of WebKit: 1. Download and uncompress the TestCase.zip into a directory called TestCase. 1. Launch MiniBrowser and open a new WK1 window. 2. Navigate to TestCase/test.html. 3. Drag and drop the PDF (the content demarcated with a black border on the page) within the web view. 4. Quit MiniBrowser. Then MiniBrowser will crash with a backtrace of the form: #0 0x0000000104d84e37 in ::-[NSPasteboard(WebExtras) _web_writePromisedRTFDFromArchive:containsImage:](WebArchive *, BOOL) at /Volumes/.../OpenSource/Source/WebKitLegacy/mac/Misc/WebNSPasteboardExtras.mm:220 #1 0x0000000104d1016b in ::-[WebHTMLView(WebPrivate) pasteboard:provideDataForType:](NSPasteboard *, NSString *) at /Volumes/.../OpenSource/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm:2013 #2 0x00007fff4fe31bf8 in __68-[NSPasteboard _setOwner:forTypes:atIndex:selector:usesPboardTypes:]_block_invoke () #3 0x00007fff5226e3fd in -[_CFPasteboardEntry resolveLocalPromisedData] () #4 0x00007fff52272296 in ___CFPasteboardHandleFulfillMessage_block_invoke.591 () #5 0x00007fff521bb22c in __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ () #6 0x00007fff5219da9b in __CFRunLoopDoBlocks () #7 0x00007fff5219d0ee in __CFRunLoopRun () #8 0x00007fff5219c940 in CFRunLoopRunSpecific () #9 0x00007fff52229c95 in CFPasteboardResolveAllPromisedData () #10 0x00007fff521b2bbc in __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ () #11 0x00007fff521b2a95 in _CFXRegistrationPost () #12 0x00007fff521b27d1 in ___CFXNotificationPost_block_invoke () #13 0x00007fff52170432 in -[_CFXNotificationRegistrar find:object:observer:enumerator:] () #14 0x00007fff5216f4c1 in _CFXNotificationPost () #15 0x00007fff54481e41 in -[NSNotificationCenter postNotificationName:object:userInfo:] () #16 0x00007fff4f97db63 in -[NSApplication terminate:] () #17 0x00007fff4fefb804 in -[NSApplication(NSResponder) sendAction:to:from:] () #18 0x00007fff4f9c6dcf in -[NSMenuItem _corePerformAction] () #19 0x00007fff4f9c6b53 in -[NSCarbonMenuImpl performActionWithHighlightingForItemAtIndex:] () #20 0x00007fff4f9c59b5 in -[NSMenu performKeyEquivalent:] () #21 0x00007fff4fefa48d in routeKeyEquivalent () #22 0x00007fff4fef7962 in -[NSApplication(NSEvent) sendEvent:] () #23 0x00007fff4f7a3294 in -[NSApplication run] () #24 0x00007fff4f772c87 in NSApplicationMain () #25 0x0000000100005a8b in main at /Volumes/.../OpenSource/Tools/MiniBrowser/mac/main.m:32
Attachments
TestCase (8.05 KB, application/zip)
2018-03-29 15:26 PDT, Daniel Bates
no flags
Patch and manual test (20.15 KB, patch)
2018-03-29 17:06 PDT, Daniel Bates
no flags
Patch and manual test (20.15 KB, patch)
2018-03-30 09:55 PDT, Daniel Bates
no flags
Patch and manual test (14.68 KB, patch)
2018-04-20 12:42 PDT, Daniel Bates
mitz: review+
Daniel Bates
Comment 1 2018-03-29 15:26:58 PDT
Created attachment 336809 [details] TestCase
Daniel Bates
Comment 2 2018-03-29 17:06:27 PDT
Created attachment 336821 [details] Patch and manual test
Daniel Bates
Comment 3 2018-03-30 09:55:36 PDT
Created attachment 336865 [details] Patch and manual test Post same patch so that EWS can process now that the patch for bug #184154 landed.
Per Arne Vollan
Comment 4 2018-03-30 11:11:49 PDT
Comment on attachment 336865 [details] Patch and manual test R=me.
Daniel Bates
Comment 5 2018-03-30 14:01:42 PDT
Comment on attachment 336865 [details] Patch and manual test Clearing flags on attachment: 336865 Committed r230117: <https://trac.webkit.org/changeset/230117>
Daniel Bates
Comment 6 2018-03-30 14:01:43 PDT
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 7 2018-03-30 14:02:56 PDT
Daniel Bates
Comment 8 2018-04-20 12:40:00 PDT
Reverted r230117 for reason: Broke find-in-page for PDFs Committed r230847: <https://trac.webkit.org/changeset/230847>
Daniel Bates
Comment 9 2018-04-20 12:42:22 PDT
Created attachment 338453 [details] Patch and manual test
mitz
Comment 10 2018-04-24 17:58:08 PDT
Comment on attachment 338453 [details] Patch and manual test View in context: https://bugs.webkit.org/attachment.cgi?id=338453&action=review > Source/WebKitLegacy/mac/ChangeLog:9 > + Fixes an assertion failure when quiting an app that uses a Legacy WebKit web view after dragging-and- typo: quiting > Source/WebKitLegacy/mac/ChangeLog:13 > + from the main frame's WebHTMLView and promise AppKit that will provide a Rich Text Format (RTF) document “that we will provide” or “to provide”
Daniel Bates
Comment 11 2018-04-26 11:41:24 PDT
(In reply to mitz from comment #10) > Comment on attachment 338453 [details] > Patch and manual test > > View in context: > https://bugs.webkit.org/attachment.cgi?id=338453&action=review > > > Source/WebKitLegacy/mac/ChangeLog:9 > > + Fixes an assertion failure when quiting an app that uses a Legacy WebKit web view after dragging-and- > > typo: quiting > Will fix before landing. > > Source/WebKitLegacy/mac/ChangeLog:13 > > + from the main frame's WebHTMLView and promise AppKit that will provide a Rich Text Format (RTF) document > > “that we will provide” or “to provide” Will fix before landing.
Daniel Bates
Comment 12 2018-04-26 11:44:53 PDT
Comment on attachment 338453 [details] Patch and manual test View in context: https://bugs.webkit.org/attachment.cgi?id=338453&action=review >>> Source/WebKitLegacy/mac/ChangeLog:13 >>> + from the main frame's WebHTMLView and promise AppKit that will provide a Rich Text Format (RTF) document >> >> “that we will provide” or “to provide” > > Will fix before landing. Will use "that we will provide"
Daniel Bates
Comment 13 2018-04-26 11:46:53 PDT
Note You need to log in before you can comment on or make changes to this bug.