Changeset 202754 in webkit
- Timestamp:
- Jul 1, 2016 1:52:30 PM (8 years ago)
- Location:
- trunk/Source/WebKit2
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/ChangeLog
r202747 r202754 1 2016-07-01 Brent Fulgham <bfulgham@apple.com> 2 3 Prevent crash when attempting to copy an image 4 https://bugs.webkit.org/show_bug.cgi?id=159288 5 <rdar://problem/23507828> 6 7 Reviewed by Brady Eidson. 8 9 WebKit could crash if the HTMLImageElement had a null cachedImage member. 10 A little investigation showed that the URL we retrieve from the cachedImage 11 is never used, so rather than adding a null check, let's just pass a 12 default argument. The actual URL gets read from elsewhere in the pasteboard 13 processing code. 14 15 * WebProcess/WebPage/ios/WebPageIOS.mm: 16 (WebKit::WebPage::performActionOnElement): Don't bother passing the 17 unused URL argument to the pasteboard method. 18 1 19 2016-07-01 Brady Eidson <beidson@apple.com> 2 20 -
trunk/Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm
r202347 r202754 2445 2445 Element* linkElement = containingLinkElement(&element); 2446 2446 if (!linkElement) 2447 m_interactionNode->document().frame()->editor().writeImageToPasteboard(*Pasteboard::createForCopyAndPaste(), element, downcast<RenderImage>(*element.renderer()).cachedImage()->url(), String());2447 m_interactionNode->document().frame()->editor().writeImageToPasteboard(*Pasteboard::createForCopyAndPaste(), element, URL(), String()); 2448 2448 else 2449 2449 m_interactionNode->document().frame()->editor().copyURL(linkElement->document().completeURL(stripLeadingAndTrailingHTMLSpaces(linkElement->fastGetAttribute(HTMLNames::hrefAttr))), linkElement->textContent());
Note: See TracChangeset
for help on using the changeset viewer.