Skip to content
Snippets Groups Projects
Commit 64f6bd0f authored by Martin Stjernholm's avatar Martin Stjernholm
Browse files

Can't simply look for _encode_object in every object, since if it's a

Remote.Obj object it will happily return a Call object then. Thus no remote
objects were encoded correctly when sent back.

Rev: lib/modules/Remote.pmod/call.pike:1.5
Rev: lib/modules/Remote.pmod/context.pike:1.10
Rev: lib/modules/Remote.pmod/obj.pike:1.3
parent b29cd3e7
No related branches found
No related tags found
No related merge requests found
#include "remote.h"
constant is_remote_call = 1;
string objectid;
string name;
object con;
......
......@@ -97,7 +97,7 @@ array encode(mixed val)
{
if (intp(val) || floatp(val))
return ({ CTX_OTHER, val });
if (objectp(val) && !val->_encode_object)
if (objectp(val) && (object_program(val)->is_remote_obj || !val->_encode_object))
return ({ CTX_OBJECT, id_for(val) });
if (functionp(val) || programp(val))
return ({ CTX_FUNCTION, id_for(val) });
......
#include "remote.h"
constant is_remote_obj = 1;
string id;
object con;
object ctx;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment