Skip to content
  • darin@apple.com's avatar
    2010-09-30 Darin Adler <darin@apple.com> · 7b7981bb
    darin@apple.com authored
            Reviewed by Sam Weinig.
    
            Remove remaining calls to deprecatedParseURL
            https://bugs.webkit.org/show_bug.cgi?id=26599
    
            * WebCoreSupport/WebFrameLoaderClient.cpp:
            (WebFrameLoaderClient::dispatchDidFailToStartPlugin):
            Call stripLeadingAndTrailingHTMLSpaces instead of deprecatedParseURL.
    2010-09-30  Darin Adler  <darin@apple.com>
    
            Reviewed by Sam Weinig.
    
            Remove remaining calls to deprecatedParseURL
            https://bugs.webkit.org/show_bug.cgi?id=26599
    
            * DOM/WebDOMOperations.mm:
            (-[DOMDocument URLWithAttributeString:]):
            * WebCoreSupport/WebFrameLoaderClient.mm:
            (WebFrameLoaderClient::createPlugin):
            Call stripLeadingAndTrailingHTMLSpaces instead of deprecatedParseURL.
    2010-09-30  Darin Adler  <darin@apple.com>
    
            Reviewed by Sam Weinig.
    
            Remove remaining calls to deprecatedParseURL
            https://bugs.webkit.org/show_bug.cgi?id=26599
    
            Test: fast/replaced/object-param-spaces.html
    
            * css/CSSHelper.cpp: Removed.
            * css/CSSHelper.h: Removed deprecatedParseURL.
    
            * html/parser/HTMLParserIdioms.cpp:
            (WebCore::stripLeadingAndTrailingHTMLSpaces):
            Fixed bug where the function would turn the null string into the empty string.
            Fixed bug where the function would not strip all trailing spaces.
    
            * html/parser/CSSPreloadScanner.cpp:
            (WebCore::CSSPreloadScanner::CSSPreloadScanner): Initialize m_state
            instead of calling the reset function.
            (WebCore::CSSPreloadScanner::scan): Tweaked coding style.
            (WebCore::CSSPreloadScanner::tokenize): Use isHTMLSpace instead of
            an identical local function named isWhitespace.
            (WebCore::parseCSSStringOrURL): Added. This function does what
            deprecatedParseURL did before, and this is the only place in WebKit
            that needs it. The code implements the rules for a string or URL
            token. The real CSS parser does this with flex and the code to hook
            flex up to yacc, so the function is not needed there.
            (WebCore::CSSPreloadScanner::emitRule): Streamlined the code a bit
            and mae it call parseCSSStringOrURL.
    
            * bindings/generic/BindingSecurity.h:
            (WebCore::::allowSettingFrameSrcToJavascriptUrl):
            * bindings/js/JSDOMBinding.cpp:
            (WebCore::allowSettingSrcToJavascriptURL):
            * bindings/js/JSHTMLFrameElementCustom.cpp:
            (WebCore::allowSettingJavascriptURL):
            * bindings/objc/DOM.mm:
            (-[DOMElement _getURLAttribute:]):
            * bindings/objc/DOMHTML.mm:
            (-[DOMHTMLDocument _createDocumentFragmentWithMarkupString:baseURLString:]):
            * dom/Document.cpp:
            (WebCore::Document::processBaseElement):
            * dom/Element.cpp:
            (WebCore::isAttributeToRemove):
            (WebCore::Element::getURLAttribute):
            (WebCore::Element::getNonEmptyURLAttribute):
            * html/HTMLAnchorElement.cpp:
            (WebCore::HTMLAnchorElement::defaultEventHandler):
            (WebCore::HTMLAnchorElement::parseMappedAttribute):
            (WebCore::HTMLAnchorElement::href):
            * html/HTMLBodyElement.cpp:
            (WebCore::HTMLBodyElement::parseMappedAttribute):
            * html/HTMLEmbedElement.cpp:
            (WebCore::HTMLEmbedElement::parseMappedAttribute):
            * html/HTMLFrameElementBase.cpp:
            (WebCore::HTMLFrameElementBase::parseMappedAttribute):
            * html/HTMLImageElement.cpp:
            (WebCore::HTMLImageElement::parseMappedAttribute):
            * html/HTMLImageLoader.cpp:
            (WebCore::HTMLImageLoader::sourceURI):
            * html/HTMLLinkElement.cpp:
            (WebCore::HTMLLinkElement::parseMappedAttribute):
            * html/HTMLMediaElement.cpp:
            * html/HTMLObjectElement.cpp:
            (WebCore::HTMLObjectElement::parseMappedAttribute):
            (WebCore::HTMLObjectElement::parametersForPlugin):
            * html/HTMLTableElement.cpp:
            (WebCore::HTMLTableElement::parseMappedAttribute):
            * html/HTMLTablePartElement.cpp:
            (WebCore::HTMLTablePartElement::parseMappedAttribute):
            * html/parser/HTMLPreloadScanner.cpp:
            (WebCore::HTMLNames::PreloadTask::setUrlToLoad):
            * loader/FormSubmission.cpp:
            (WebCore::FormSubmission::Attributes::parseAction):
            * platform/chromium/ClipboardChromium.cpp:
            (WebCore::ClipboardChromium::declareAndWriteDragImage):
            * platform/chromium/PasteboardChromium.cpp:
            (WebCore::Pasteboard::writeImage):
            * platform/qt/ClipboardQt.cpp:
            (WebCore::ClipboardQt::declareAndWriteDragImage):
            * platform/win/ClipboardWin.cpp:
            (WebCore::ClipboardWin::declareAndWriteDragImage):
            * rendering/HitTestResult.cpp:
            (WebCore::HitTestResult::absoluteImageURL):
            (WebCore::HitTestResult::absoluteMediaURL):
            (WebCore::HitTestResult::absoluteLinkURL):
            * svg/SVGAElement.cpp:
            (WebCore::SVGAElement::defaultEventHandler):
            * svg/SVGImageLoader.cpp:
            (WebCore::SVGImageLoader::sourceURI):
            * wml/WMLAElement.cpp:
            (WebCore::WMLAElement::defaultEventHandler):
            * wml/WMLImageLoader.cpp:
            (WebCore::WMLImageLoader::sourceURI):
            Call stripLeadingAndTrailingHTMLSpaces instead of deprecatedParseURL.
    
            * WebCore.exp.in: Updated.
    
            * Android.mk: Removed CSSHelper.cpp.
            * CMakeLists.txt: Ditto.
            * GNUmakefile.am: Ditto.
            * WebCore.gypi: Ditto.
            * WebCore.pro: Ditto.
            * WebCore.vcproj/WebCore.vcproj: Ditto.
            * WebCore.xcodeproj/project.pbxproj: Ditto.
    
            * bindings/js/JSAttrCustom.cpp:
            * bindings/js/JSElementCustom.cpp:
            * bindings/v8/custom/V8ElementCustom.cpp:
            * bindings/v8/custom/V8LocationCustom.cpp:
            * css/CSSParser.cpp:
            * html/HTMLMediaElement.cpp:
            * html/HTMLVideoElement.cpp:
            * loader/ImageLoader.cpp:
            * rendering/style/RenderStyle.h:
            Removed unneeded include of CSSHelper.h.
    2010-09-30  Darin Adler  <darin@apple.com>
    
            Reviewed by Sam Weinig.
    
            Remove remaining calls to deprecatedParseURL
            https://bugs.webkit.org/show_bug.cgi?id=26599
    
            * fast/replaced/object-param-spaces-expected.txt: Copied from
            LayoutTests/fast/replaced/object-param-url-control-char-expected.txt.
            * fast/replaced/object-param-spaces.html: Copied from
            LayoutTests/fast/replaced/object-param-url-control-char.html.
            * fast/replaced/object-param-url-control-char-expected.txt: Removed.
            * fast/replaced/object-param-url-control-char.html: Removed.
            Changed this test to expect HTML standard space trimming, but not the WebKit-only
            control character stripping we had historically.
    
            * fast/url/query-expected.txt: Updated to expect the test to pass.
    
            * fast/url/script-tests/segments-from-data-url.js: Changed expected result to not
            expect stripping of newline characters.
            * fast/url/script-tests/segments.js: Ditto.
            * fast/url/segments-expected.txt: Updated results.
            * fast/url/segments-from-data-url-expected.txt: Ditto.
    
            * http/tests/security/javascriptURL/javascriptURL-execution-context-frame-location-htmldom-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-frame-src-getAttribute-value-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-frame-src-htmldom-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-frame-src-setAttribute-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-frame-src-setAttributeNS-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-frame-src-setAttributeNode-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-frame-src-setAttributeNodeNS-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-iframe-src-getAttribute-value-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-iframe-src-htmldom-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-iframe-src-setAttribute-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-iframe-src-setAttributeNS-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-iframe-src-setAttributeNode-expected.txt:
            * http/tests/security/javascriptURL/javascriptURL-execution-context-iframe-src-setAttributeNodeNS-expected.txt:
            These tests had multiple test cases with embedded control characters. These URLs no
            longer qualify as javascript URLs, so there are no longer any unsafe JavaScript log
            messages for them. The test cases themselves need not be changed at this time.
    
            * http/tests/security/xssAuditor/embed-tag-control-char-expected.txt:
            * http/tests/security/xssAuditor/object-embed-tag-control-char-expected.txt:
            Updated expected results to reflect the fact that the control character is no longer
            stripped from the URL in these cases. The test is still valid, but these are not as
            interesting test cases any more since control characters do not have special handling.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@68854 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    7b7981bb