From 51bb4d8e92c53ca620f71d11dc4d29d33cf6ff7b Mon Sep 17 00:00:00 2001 From: Par Winzell Date: Wed, 19 Mar 2008 07:25:36 +0000 Subject: [PATCH] I am tentatively meddling with Ray's code because pointer comparison on the class fails for objects that are instantiated... elsewhere. Different application domain? Testing on the full class name ought to be safe. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4973 542714f4-19e9-0310-aa3c-eee0fc999fb1 --- src/as/com/threerings/util/ObjectMarshaller.as | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/as/com/threerings/util/ObjectMarshaller.as b/src/as/com/threerings/util/ObjectMarshaller.as index 86a663c0b..172548d73 100644 --- a/src/as/com/threerings/util/ObjectMarshaller.as +++ b/src/as/com/threerings/util/ObjectMarshaller.as @@ -166,7 +166,7 @@ public class ObjectMarshaller if (type == "number" || type == "string" || type == "boolean" ) { return null; // kosher! } - if (-1 != VALID_CLASSES.indexOf(ClassUtil.getClass(value))) { + if (-1 != VALID_CLASSES.indexOf(ClassUtil.getClassName(value))) { return null; // kosher } if (!Util.isPlainObject(value)) { @@ -187,6 +187,8 @@ public class ObjectMarshaller } /** Non-simple classes that we allow, as long as they are not subclassed. */ - protected static const VALID_CLASSES :Array = [ ByteArray, Point, Rectangle ]; + protected static const VALID_CLASSES :Array = [ + "flash.utils.ByteArray", "flash.geom.Point", "flash.geom.Rectangle" + ]; } }