Bug 42961 - Web Inspector: make sure proxy objects are JSON-stringifiable.
Summary: Web Inspector: make sure proxy objects are JSON-stringifiable.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Pavel Feldman
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-26 02:51 PDT by Pavel Feldman
Modified: 2010-07-26 14:29 PDT (History)
11 users (show)

See Also:


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

Note You need to log in before you can comment on or make changes to this bug.
Description Pavel Feldman 2010-07-26 02:51:49 PDT
Patch to follow.
Comment 1 Pavel Feldman 2010-07-26 02:55:02 PDT
Created attachment 62551 [details]
[PATCH] Proposed fix.
Comment 2 Shinichiro Hamaji 2010-07-26 04:13:58 PDT
Comment on attachment 62551 [details]
[PATCH] Proposed fix.

Looks good
Comment 3 Pavel Feldman 2010-07-26 04:21:59 PDT
Committing to http://svn.webkit.org/repository/webkit/trunk ...
	M	WebCore/ChangeLog
	M	WebCore/inspector/front-end/InjectedScript.js
Committed r64040
Comment 4 WebKit Review Bot 2010-07-26 04:28:11 PDT
http://trac.webkit.org/changeset/64040 might have broken Qt Linux Release minimal
Comment 5 Joseph Pecoraro 2010-07-26 09:45:07 PDT
Which value was breaking this such that !! fixed the problem?
Comment 6 Pavel Feldman 2010-07-26 14:29:14 PDT
(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...