[Webkit-unassigned] [Bug 51528] New: ScriptController::evaluate returns empty result for undefined. Can't distinguish errors from undefined results.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Dec 23 03:02:15 PST 2010


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

           Summary: ScriptController::evaluate returns empty result for
                    undefined. Can't distinguish errors from undefined
                    results.
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: PC
        OS/Version: Mac OS X 10.5
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: WebCore JavaScript
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: tom.rathbone at gmail.com


ScriptController::evaluate contains:

    if (object.IsEmpty() || object->IsUndefined())
        return ScriptValue();

Should be:

    if (object.IsEmpty())
        return ScriptValue();

Returning an empty ScriptValue should indicate an error. As undefined is a valid return value for void calls returning an empty ScriptValue makes it impossible to distinguish undefined results from errors.

Related mailing list thread:

https://lists.webkit.org/pipermail/webkit-dev/2010-December/015417.html

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