I have a guest API function (inside a GWT JSNI method) whose body is this:
var point = {x:10, y:10, z:10};
$wnd.caja.markReadOnlyRecord(point);
var point_tamed = $wnd.caja.tame(point);
return point_tamed;
I'm basing this off of the guide here:
https://developers.google.com/caja/docs/allowingcooperation/. This guide is
taming objects that are sent back as arguments to a callback, so maybe it
doesn't apply, but when I call my function from guest code, I get this
error:
Uncaught script error: Tame object found on feral side of taming membrane:
[object Object]. The membrane has previously been compromised. in source:
"unknown" at line: 0
Suffice to say that this function is being marked and tamed the same way as
all my other API functions, and they seem to work correctly, but I can
provide contextual code if needed. My other functions are either purely
procedural, or return a string or numeric primitive. If I don't tame the
point, and just return the point as is (which the error seems to imply is
the solution), the guest code receives the object without problems, but not
sure if that's safe or not.
Thanks for any help!
--
---
You received this message because you are subscribed to the Google Groups
"Google Caja Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.