[Webkit-unassigned] [Bug 29193] [chromium] Prevent JavaScript busy-loops in unload handlers

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Sep 16 14:13:04 PDT 2009


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





--- Comment #27 from Adam Barth <abarth at webkit.org>  2009-09-16 14:13:01 PDT ---
(In reply to comment #26)
> > 1) I think we should give web developers a bigger carrot to avoid an arms race
> > here.  In particular, we should consider completing network requests started
> > from unload handlers, removing the incentive to use a busy-loop.
> 
> There are a variety of serious problems with this.  Peter just touched on some
> of them.  This been discussed to death already.

Are you referring to the passage where Peter says doing this provides authors
no incentive to switch to <a ping>?  Darin also noted on IRC that this might
slow down loading a new page from the same server.

I think the main disagreement here is over how we think authors will respond to
various incentives.  I don't think any of us know for sure.  As you've pointed
out, they might even just ignore us given our market share.

> > 2) I continue to think that WebCore is the wrong layer at which to make a
> > change that manipulates the Date API.  The reasons to prefer making the change
> > here appear more political than technical.
> 
> The (technical) reasons why this is the case have been made a number of times. 
> V8 team does not want to add hooks as it's too one-off, and it limits their
> flexibility.  We will need hooks anyways in the bindings layer to know when
> we're entering/exiting an unload handler.

I could say the same thing here.  Why not implement this in the browser process
by sending an evalJavaScript IPC message?  The only reason this patch is
technically possible is because the Date API happens to be stored in a global
variable.  Do you really think this patch isn't breaking the abstraction
barrier?  (That's even ignoring all the web-visible side-effect of monkeying
around with the global namespace.)

-- 
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