From 542055c95151c071df60ea88a6fd0142218b3915 Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Thu, 13 Dec 2012 01:29:10 +0100 Subject: [PATCH] Fix return values for Object.protoype.seal/freeze/preventExtensions Change-Id: Icc9844cfac5d8afae09ca10eeed024e65385801f Reviewed-by: Simon Hausmann --- qv4ecmaobjects.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qv4ecmaobjects.cpp b/qv4ecmaobjects.cpp index bb3cd5f..eb3dbd4 100644 --- a/qv4ecmaobjects.cpp +++ b/qv4ecmaobjects.cpp @@ -689,7 +689,7 @@ Value ObjectPrototype::method_seal(ExecutionContext *ctx) ++it; } } - return Value::undefinedValue(); + return ctx->argument(0); } Value ObjectPrototype::method_freeze(ExecutionContext *ctx) @@ -708,7 +708,7 @@ Value ObjectPrototype::method_freeze(ExecutionContext *ctx) ++it; } } - return Value::undefinedValue(); + return ctx->argument(0); } Value ObjectPrototype::method_preventExtensions(ExecutionContext *ctx) @@ -718,7 +718,7 @@ Value ObjectPrototype::method_preventExtensions(ExecutionContext *ctx) Object *o = ctx->argument(0).objectValue(); o->extensible = false; - return Value::undefinedValue(); + return ctx->argument(0); } Value ObjectPrototype::method_isSealed(ExecutionContext *ctx) -- 2.7.4