[Webkit-unassigned] [Bug 18608] [Gtk] WebKitNetworkRequest needs to be finished

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jul 29 03:26:26 PDT 2008


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





------- Comment #14 from marco.barisione at collabora.co.uk  2008-07-29 03:26 PDT -------
(In reply to comment #13)
> +    ResourceRequest requestCopy = resourceRequest;
> +    WebKitNetworkRequest* request = webkit_network_request_new_from_resource_request(requestCopy);

Why a copy is then the request is copied again to priv->request?


> +gdouble webkit_network_request_get_timeout_interval(WebKitNetworkRequest* request)
> +{
> +    g_return_val_if_fail(WEBKIT_IS_NETWORK_REQUEST(request), 0.0);
> +
> +    WebKitNetworkRequestPrivate* priv = request->priv;
> +
> +    return (gdouble)priv->request.timeoutInterval();
> +}

You don't need the cast from double to gdouble.


> +const GHashTable* webkit_network_request_get_http_headers(WebKitNetworkRequest* request)
> +{
> +    g_return_val_if_fail(WEBKIT_IS_NETWORK_REQUEST(request), NULL);
> +
> +    return webkit_network_request_private_get_http_headers(request);
> +}

Why do you have a separate webkit_network_request_private_get_http_headers?


> + * For instance: if the request already has a X-Misc header with a
> + * value of "go, webkit!", and we add the same X-Misc header
> + * containing "go!" we will end up having a single X-Misc header with
> + * a value of "go, webkit!,go!".

Maybe the example would be clearer if you use a real header, like
Accept-Language.


> +void webkit_network_response_set_uri(WebKitNetworkResponse* response, const gchar* uri)
> +{
> +    g_return_if_fail(WEBKIT_IS_NETWORK_RESPONSE(response));
> +    g_return_if_fail(uri);
> +
> +    WebKitNetworkResponsePrivate* priv = response->priv;
> +
> +    g_free(priv->uri);
> +    priv->uri = g_strdup(uri);
> +
> +    /* 
> +     * feeding back to the ResourceResponse object, which is the one actually used
> +     * inside WebCore
> +     */
> +    priv->response.setUrl(KURL(String::fromUTF8(uri)));
> +}

g_object_notify is missing.


Can a native English speaker check if the documentation is ok?


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



More information about the webkit-unassigned mailing list