Bug 62122 - window.onerror broke m.facebook.com
Summary: window.onerror broke m.facebook.com
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Evangelism (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2011-06-06 05:45 PDT by Krzysztof Czech
Modified: 2011-10-27 08:53 PDT (History)
8 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Krzysztof Czech 2011-06-06 05:45:37 PDT
I found a problem on http://m.facebook.com site. Generally problem occurs on registration form when one of the select controls  with date is clicked. It could be either "year", "month" or "day" control. Browser shows an error page with "Connection error" message. Accordingly WebCore reports an exception with an error message, "Can't find variable: bagofholding". It looks like "bugofholding" might be some javascript. Unfortunately it could not be found.

Basically, the situation with error page happens with this commit "c8a06eb946ed0cbe5c144daa894c1fdb5d9f190a".
Precisely in ScriptExecutionContext::reportException method, as soon as execution flow reaches 
dispatchErrorEvent method.
Comment 1 Yury Semikhatsky 2011-06-06 06:55:19 PDT
Looks like the problem is in the site which sets error handler using window.onerror = ... and the handler is invoked for "Uncaught ReferenceError: bagofholding is not defined" which is expected behavior of window.onerror. Before the change you mentioned window.onerror didn't work in WebKit and no uncaught exceptions would reach window.onerror handler.
Comment 2 Alexey Proskuryakov 2011-06-06 14:14:39 PDT
<rdar://problem/9560131>
Comment 3 Alexey Proskuryakov 2011-10-27 08:53:41 PDT
I'm told that Facebook fixed this.