Bug 42961 - Web Inspector: make sure proxy objects are JSON-stringifiable.
: Web Inspector: make sure proxy objects are JSON-stringifiable.
Status: RESOLVED FIXED
: WebKit
Web Inspector (Deprecated)
: 528+ (Nightly build)
: All All
: P2 Normal
Assigned To:
:
:
:
:
  Show dependency treegraph
 
Reported: 2010-07-26 02:51 PST by
Modified: 2010-07-26 14:29 PST (History)


Attachments
[PATCH] Proposed fix. (1.31 KB, patch)
2010-07-26 02:55 PST, Pavel Feldman
hamaji: review+
Review Patch | Details | Formatted Diff | Diff


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2010-07-26 02:51:49 PST
Patch to follow.
------- Comment #1 From 2010-07-26 02:55:02 PST -------
Created an attachment (id=62551) [details]
[PATCH] Proposed fix.
------- Comment #2 From 2010-07-26 04:13:58 PST -------
(From update of attachment 62551 [details])
Looks good
------- Comment #3 From 2010-07-26 04:21:59 PST -------
Committing to http://svn.webkit.org/repository/webkit/trunk ...
    M    WebCore/ChangeLog
    M    WebCore/inspector/front-end/InjectedScript.js
Committed r64040
------- Comment #4 From 2010-07-26 04:28:11 PST -------
http://trac.webkit.org/changeset/64040 might have broken Qt Linux Release minimal
------- Comment #5 From 2010-07-26 09:45:07 PST -------
Which value was breaking this such that !! fixed the problem?
------- Comment #6 From 2010-07-26 14:29:14 PST -------
(In reply to comment #5)
> Which value was breaking this such that !! fixed the problem?

I guess it was object with no own property names:

type === "object" && object !== null && (Object.getOwnPropertyNames(object).length || object.__proto__)) || type === "function"

evaluated to "object.__proto__" that was non-boolean. Then proto was serialized which was wrong thing to do...