Ignore:
Timestamp:
Nov 17, 2009, 12:41:10 AM (16 years ago)
Author:
[email protected]
Message:

Incorrect use of JavaScriptCore API in DumpRenderTree
https://bugs.webkit.org/show_bug.cgi?id=31577

Reviewed by Maciej Stachowiak

Return undefined rather than a literal null.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/API/tests/testapi.c

    r50964 r51068  
    167167        return JSValueMakeUndefined(context);
    168168    }
     169   
     170    if (JSStringIsEqualToUTF8CString(propertyName, "hasPropertyLie")) {
     171        return 0;
     172    }
    169173
    170174    if (JSStringIsEqualToUTF8CString(propertyName, "throwOnGet")) {
     
    177181    }
    178182   
    179     return NULL;
     183    return JSValueMakeNull(context);
    180184}
    181185
     
    300304
    301305    // string conversion -- forward to default object class
    302     return NULL;
     306    return JSValueMakeNull(context);
    303307}
    304308
     
    375379        break;
    376380    default:
    377         return NULL;
     381        return JSValueMakeNull(context);
    378382        break;
    379383    }
     
    383387    JSObjectRef function = JSValueToObject(context, func, exception);
    384388    if (!function)
    385         return NULL;
     389        return JSValueMakeNull(context);
    386390    JSValueRef value = JSObjectCallAsFunction(context, function, object, 0, NULL, exception);
    387391    if (!value) {
Note: See TracChangeset for help on using the changeset viewer.