Index: fxjs/cfxjse_class.cpp |
diff --git a/fxjs/cfxjse_class.cpp b/fxjs/cfxjse_class.cpp |
index de22af7681798e933f06017f2524c04c184cca3f..6ccc0e2e240a7711af0432a46de39154eacf29af 100644 |
--- a/fxjs/cfxjse_class.cpp |
+++ b/fxjs/cfxjse_class.cpp |
@@ -289,9 +289,10 @@ void NamedPropertySetterCallback( |
new CFXJSE_Value(info.GetIsolate())); |
lpThisValue->ForceSetValue(thisObject); |
- CFXJSE_Value* lpNewValue = new CFXJSE_Value(info.GetIsolate()); |
+ std::unique_ptr<CFXJSE_Value> lpNewValue(new CFXJSE_Value(info.GetIsolate())); |
lpNewValue->ForceSetValue(value); |
- DynPropSetterAdapter(lpClass, lpThisValue.get(), szFxPropName, lpNewValue); |
+ DynPropSetterAdapter(lpClass, lpThisValue.get(), szFxPropName, |
+ lpNewValue.get()); |
info.GetReturnValue().Set(value); |
} |