зеркало из https://github.com/mozilla/gecko-dev.git
Bug 887521 - Fix OnUnknownMethod to not modify vp if there's no __noSuchMethod__ method. r=jwalden
This commit is contained in:
Родитель
65a40b5804
Коммит
3345b24b2d
|
@ -212,9 +212,7 @@ js::OnUnknownMethod(JSContext *cx, HandleObject obj, Value idval_, MutableHandle
|
|||
|
||||
TypeScript::MonitorUnknown(cx);
|
||||
|
||||
if (value.get().isPrimitive()) {
|
||||
vp.set(value);
|
||||
} else {
|
||||
if (value.isObject()) {
|
||||
JSObject *obj = NewObjectWithClassProto(cx, &js_NoSuchMethodClass, NULL, NULL);
|
||||
if (!obj)
|
||||
return false;
|
||||
|
|
Загрузка…
Ссылка в новой задаче