From a7eb97b930bbbd3133f336a6f2ccbfb55eebbcfb Mon Sep 17 00:00:00 2001 From: Rainer Gerhards Date: Fri, 29 Feb 2008 16:02:07 +0000 Subject: - added "debug" command to debug environment settings - changed the object/interface system to use a new way of calling, giving up the numerical object ID. This was necessary as we needed more extensibility for third-party modules (which don't play at all with the previous fixed object ID). This is stage work for the object loader. Please note that I needed to change the object (de)serializer, I can't outrule that I have introduced bugs there. --- conf.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'conf.c') diff --git a/conf.c b/conf.c index 1229f1c4..9ac85d34 100644 --- a/conf.c +++ b/conf.c @@ -55,6 +55,7 @@ #include "srUtils.h" /* static data */ +DEFobjCurrIf(obj) DEFobjCurrIf(expr) DEFobjCurrIf(ctok) #include "vm.h" @@ -1174,15 +1175,19 @@ cfline(uchar *line, selector_t **pfCurr) } +/* dummy */ +//static rsRetVal confQueryInterface(void) { return RS_RET_NOT_IMPLEMENTED; } + /* "mimic" a real object - we are currently not one... */ rsRetVal confClassInit(void) { DEFiRet; /* request objects we use */ - CHKiRet(objUse(expr)); - CHKiRet(objUse(ctok)); - CHKiRet(objUse(vm)); // TODO: remove, testing aid! rgerhards, 2008-02-25 - CHKiRet(objUse(var)); // TODO: remove, testing aid! rgerhards, 2008-02-25 + CHKiRet(objGetObjInterface(&obj)); /* this provides the root pointer for all other queries */ + CHKiRet(objUse(expr, CORE_COMPONENT)); + CHKiRet(objUse(ctok, CORE_COMPONENT)); + CHKiRet(objUse(vm, CORE_COMPONENT)); // TODO: remove, testing aid! rgerhards, 2008-02-25 + CHKiRet(objUse(var, CORE_COMPONENT)); // TODO: remove, testing aid! rgerhards, 2008-02-25 finalize_it: RETiRet; -- cgit