[Webkit-unassigned] [Bug 49838] Image Subresource Loads Should Not Prevent Page Cache Entry

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Nov 29 12:43:37 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=49838





--- Comment #4 from Darin Adler <darin at apple.com>  2010-11-29 12:43:36 PST ---
(From update of attachment 74432)
View in context: https://bugs.webkit.org/attachment.cgi?id=74432&action=review

> WebCore/history/PageCache.cpp:259
> +        && (documentLoader->mainDocumentError().isNull() || (documentLoader->mainDocumentError().isCancellation() && documentLoader->subresourceLoadersArePageCacheAcceptable()))

What tells us that cancellation is specifically due to the subresource issue? It seems like any cancellation would return true here, not just the one you mention in the comment. Are cancellations solely due to leaving the page before subresources finish loading, or are there other causes of cancellation?

> WebCore/loader/DocumentLoader.cpp:79
> +    const ResourceLoaderSet copy = loaders;

We normally don’t use const for local variables like this one.

Rather than copying the set it would be more efficient to instead use a local vector and the copyToVector function.

> WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm:388
> +        // Save the target type, because that information may be checked later on.

Is there anything else besides the target type that needs to be preserved? Maybe we should make a function that puts a new NSURLRequest in and preserves everything else.

> WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm:389
> +        ResourceRequestBase::TargetType type = request.targetType();

This can be ResourceRequest::TargetType. The use of ResourceRequestBase is an internal implementation detail that we normally should ignore.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list