Fixed:
authorcblu <cblu@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 4 May 2005 18:50:56 +0000 (18:50 +0000)
committercblu <cblu@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 4 May 2005 18:50:56 +0000 (18:50 +0000)
commit4785d34d60b0ed59afa4a2ef3b844d2195befd9f
treee3af4184049a163b64a7aaca8a7920b350710bce
parent3fde383d5e6a64061f733ee2b6d343f8571e30dc
Fixed:
<rdar://problem/4078417> REGRESSION (125-412): MLB gameday page doesn't update (Flash)
<rdar://problem/4072280> XMLHttpRequest calls onReadyStateChange callback with bogus status value

Reviewed by john.

Our WebKit-level caching of subresources "dumbed-down" information held in NSURLResponse. This caused some loads to lack response headers and thus disabling cache directives. Status codes were also not retained and this caused XMLHttpRequest to fail frequently. The fix is to have WebResource retain the NSURLResponse and to use the NSURLResponse when we decide to load from WebResources.

        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge objectLoadedFromCacheWithURL:response:data:]): call new [WebResource _initWithData:URL:response:]
        * WebView.subproj/WebBaseResourceHandleDelegate.m:
        (-[WebBaseResourceHandleDelegate _canUseResourceWithResponse:]): new, checks response cache directives
        (-[WebBaseResourceHandleDelegate loadWithRequest:]): call _canUseResourceWithResponse:
        (-[WebBaseResourceHandleDelegate saveResource]): call new [WebResource _initWithData:URL:response:]
        * WebView.subproj/WebResource.m:
        (-[WebResourcePrivate dealloc]):
        (-[WebResource initWithData:URL:MIMEType:textEncodingName:frameName:]): call renamed _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:
        (-[WebResource initWithCoder:]): decode the NSURLReponse
        (-[WebResource encodeWithCoder:]): encode the NSURLReponse
        (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]): take the NSURLReponse
        (-[WebResource _initWithData:URL:response:]): new
        (-[WebResource _initWithPropertyList:]): decode the NSURLReponse
        (-[WebResource _propertyListRepresentation]): encode the NSURLReponse
        (-[WebResource _response]): return ivar if we have one
        * WebView.subproj/WebResourcePrivate.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9104 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebKit/ChangeLog
WebKit/WebCoreSupport.subproj/WebBridge.m
WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
WebKit/WebView.subproj/WebLoader.m
WebKit/WebView.subproj/WebResource.m
WebKit/WebView.subproj/WebResourcePrivate.h