Similar to webkit_uri_request_get_http_headers
Created attachment 237142 [details] Patch
Thanks for the patch. If this patch contains new public API please make sure it follows the guidelines for new WebKit2 GTK+ API. See http://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
Attachment 237142 [details] did not pass style-queue: WARNING: File exempt from style guide. Skipping: "Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.h" ERROR: Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.cpp:172: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.cpp:173: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.cpp:174: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] ERROR: Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.cpp:175: Weird number of spaces at line-start. Are you using a 4-space indent? [whitespace/indent] [3] Total errors found: 4 in 9 files If any of these errors are false positives, please file a bug against check-webkit-style.
Created attachment 237143 [details] Fix coding style issues
Comment on attachment 237143 [details] Fix coding style issues View in context: https://bugs.webkit.org/attachment.cgi?id=237143&action=review > Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.cpp:280 > + if (!response->priv->resourceResponse.url().protocolIsInHTTPFamily()) Shouldn't this check be done before the previous one?
Comment on attachment 237143 [details] Fix coding style issues View in context: https://bugs.webkit.org/attachment.cgi?id=237143&action=review >> Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.cpp:280 >> + if (!response->priv->resourceResponse.url().protocolIsInHTTPFamily()) > > Shouldn't this check be done before the previous one? I don't think so, once we have a valid pointer we should return that one, no need to check again it's an HTTP response
Comment on attachment 237143 [details] Fix coding style issues View in context: https://bugs.webkit.org/attachment.cgi?id=237143&action=review LGTM >>> Source/WebKit2/UIProcess/API/gtk/WebKitURIResponse.cpp:280 >>> + if (!response->priv->resourceResponse.url().protocolIsInHTTPFamily()) >> >> Shouldn't this check be done before the previous one? > > I don't think so, once we have a valid pointer we should return that one, no need to check again it's an HTTP response The detail Sergio may have missed is that httpHeaders is only there if the resposts was for a protocal in the HTTP family. This check protects against creating httpHeaders in the first place (below).
Committed r173060: <http://trac.webkit.org/changeset/173060>