projects
/
platform
/
upstream
/
qtdeclarative.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c267edf
)
Fix a possible crash when setting a property on a primitive type
author
Lars Knoll
<lars.knoll@digia.com>
Thu, 13 Dec 2012 00:28:46 +0000
(
01:28
+0100)
committer
Simon Hausmann
<simon.hausmann@digia.com>
Wed, 12 Dec 2012 23:02:08 +0000
(
00:02
+0100)
Change-Id: Icb8d97536b87779cdc3e543260755509232e10cb
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
qmljs_runtime.cpp
patch
|
blob
|
history
diff --git
a/qmljs_runtime.cpp
b/qmljs_runtime.cpp
index
5ef2c6c
..
1768cbf
100644
(file)
--- a/
qmljs_runtime.cpp
+++ b/
qmljs_runtime.cpp
@@
-544,6
+544,8
@@
Value __qmljs_new_string_object(ExecutionContext *ctx, String *string)
void __qmljs_set_property(ExecutionContext *ctx, Value object, String *name, Value value)
{
+ if (! object.isObject())
+ object = __qmljs_to_object(object, ctx);
object.objectValue()->__put__(ctx, name, value);
}