Bug 595668 - create XPCCallContext in XPC_NW_Construct (r=mrbkap)

This commit is contained in:
Luke Wagner 2010-09-20 18:23:04 -07:00
parent 731ad72609
commit 604b7b661f

View File

@ -719,6 +719,13 @@ XPC_NW_Construct(JSContext *cx, uintN argc, jsval *vp)
return ThrowException(NS_ERROR_INVALID_ARG, cx);
}
XPCCallContext ccx(JS_CALLER, cx, obj, nsnull, JSID_VOID,
argc, JS_ARGV(cx, vp), vp);
if(!ccx.IsValid())
return JS_FALSE;
JS_ASSERT(obj == ccx.GetFlattenedJSObject());
nsresult rv = wrappedNative->GetScriptableInfo()->
GetCallback()->Construct(wrappedNative, cx, obj, argc, JS_ARGV(cx, vp), vp,
&retval);