Bug 101872

Summary: NetworkProcess: Use an accurate shouldContentSniff value when creating ResourceHandles
Product: WebKit Reporter: Brady Eidson <beidson>
Component: WebKit2Assignee: Brady Eidson <beidson>
Status: RESOLVED FIXED    
Severity: Normal CC: ap, japhet, sam, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: All   
Bug Depends on:    
Bug Blocks: 98537    
Attachments:
Description Flags
Patch v1
sam: review-
Patch v2
none
Patch v3 - Just content sniffing ap: review+

Description Brady Eidson 2012-11-11 16:09:28 PST
NetworkProcess: Use accurate shouldContentSniff and RemoteNetworkingContext values when creating ResourceHandles
Comment 1 Brady Eidson 2012-11-11 16:29:19 PST
Created attachment 173526 [details]
Patch v1

This patch should work nicely.

We might have to rethink the RemoteNetworkingContext messaging if it becomes problematic.
Comment 2 WebKit Review Bot 2012-11-11 16:31:53 PST
Attachment 173526 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1
Source/WebKit2/NetworkProcess/mac/RemoteNetworkingContext.h:44:  The parameter name "connection" adds no information, so it should be removed.  [readability/parameter_name] [5]
Total errors found: 1 in 17 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Sam Weinig 2012-11-11 17:03:54 PST
Comment on attachment 173526 [details]
Patch v1

r- since I don't think the RemoteNetworkingContext needs a connection pointer.
Comment 4 Brady Eidson 2012-11-11 17:16:15 PST
Created attachment 173528 [details]
Patch v2
Comment 5 Brady Eidson 2012-11-12 12:55:38 PST
Alexey and I discussed the RemoteNetworkingContext change in person.  Repurposing this bug to be just about content sniffing.
Comment 6 Brady Eidson 2012-11-12 12:57:52 PST
Created attachment 173696 [details]
Patch v3 - Just content sniffing
Comment 7 Alexey Proskuryakov 2012-11-12 13:10:39 PST
Comment on attachment 173696 [details]
Patch v3 - Just content sniffing

View in context: https://bugs.webkit.org/attachment.cgi?id=173696&action=review

> Source/WebKit2/NetworkProcess/NetworkResourceLoadScheduler.h:29
> +#include <WebCore/ResourceLoaderOptions.h>

I'm not sure if it's correct to use ResourceLoaderOptions in network process. There is no ResourceLoader here.
Comment 8 Brady Eidson 2012-11-12 13:31:55 PST
(In reply to comment #7)
> (From update of attachment 173696 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=173696&action=review
> 
> > Source/WebKit2/NetworkProcess/NetworkResourceLoadScheduler.h:29
> > +#include <WebCore/ResourceLoaderOptions.h>
> 
> I'm not sure if it's correct to use ResourceLoaderOptions in network process. There is no ResourceLoader here.

I think "ResourceLoaderOptions" is a misnomer for the file, and perhaps it should be called "ResourceLoadingOptions"

That's the brave new world we're charting.
Comment 9 Brady Eidson 2012-11-12 13:58:10 PST
http://trac.webkit.org/changeset/134299