[Webkit-unassigned] [Bug 144738] REGRESSION(r183861): [SOUP] Downloads are broken when using the Network Process

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu May 14 10:33:04 PDT 2015


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

--- Comment #11 from Carlos Garcia Campos <cgarcia at igalia.com> ---
(In reply to comment #9)
> > What's wrong using a ResourceHandleClient for downloads?
> 
> It's best to use cross-platform code in the same way on all ports. When we
> don't, we get bugs like this.

But the downloads implementation in mac is not cross-platform at all, no?

> > What we could do, though, is creating a new handle instead of reusing the existing one.
> 
> This seems better indeed, although it still smells like something that would
> cause trouble due to different usage scenarios for the same cross-platform
> abstraction.
> 
> > Or we could add isDownload() to ResourceHandleClient and do something like:
> 
> This is a pretty gross hack. Even though downloading is the only case where
> we swap ResourceHandleClients at this time, ResourceHandle interface in no
> way enforces that. Also, the check would be super surprising to anyone who
> looks at cross-platform and Mac code only - the libsoup behavior is hidden
> pretty well.
> 
> If the first option (using custom soup based code for downloading) is not
> practical, I would consider adding a disconnectClient(ResourceHandleClient*)
> function to ResourceHandle, which would be a no-op if the argument doesn't
> match the current client.
> 
> However, I have a suspicion that most of the code needed to reimplement
> downloading would be moved, not duplicated.

I could try to move the soup implementation to a helper class to be used by both ResourceHandle and Downloads, but that would require a lot more time. Since this is a serious regression, I prefer to fix it ASAP and then try to do it in a different way, but I still don't see why using a ResourceHandle is a problem. ResourceHandle is a good wrapper around the libsoup details, and I think we have always used a ResourceHandle for downloads, even in WebKit1.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150514/791d1afa/attachment.html>


More information about the webkit-unassigned mailing list