Index: generic/nsf.c =================================================================== diff -u -rf4279323fa74c6c84b7f66a44cbba11858cae7b3 -rb4ed9a3212e6dbbd3275c3666ea2e738816594b0 --- generic/nsf.c (.../nsf.c) (revision f4279323fa74c6c84b7f66a44cbba11858cae7b3) +++ generic/nsf.c (.../nsf.c) (revision b4ed9a3212e6dbbd3275c3666ea2e738816594b0) @@ -6150,7 +6150,7 @@ */ int NsfAddObjectMethod(Tcl_Interp *interp, Nsf_Object *object1, CONST char *methodName, Tcl_ObjCmdProc *proc, ClientData clientData, Tcl_CmdDeleteProc *dp, - int flags) nonnull(1) nonnull(2) nonnull(3) nonnull(4) nonnull(6); + int flags) nonnull(1) nonnull(2) nonnull(3) nonnull(4); int NsfAddObjectMethod(Tcl_Interp *interp, Nsf_Object *object1, CONST char *methodName, @@ -6166,7 +6166,6 @@ assert(object1); assert(methodName); assert(proc); - assert(dp); /* Check, if we are allowed to redefine the method */ result = CanRedefineCmd(interp, object->nsPtr, object, (char *)methodName); @@ -10254,7 +10253,6 @@ static Tcl_Command FilterSearchProc(Tcl_Interp *interp, NsfObject *object, Tcl_Command *currentCmd, NsfClass **clPtr) { - NsfCmdList *cmdList; assert(interp); assert(object); @@ -10268,32 +10266,36 @@ */ assert(object->flags & NSF_FILTER_ORDER_VALID); - *currentCmd = NULL; - cmdList = SeekCurrent(object->filterStack->currentCmdPtr, object->filterOrder); + if (object->filterOrder) { + NsfCmdList *cmdList; - while (cmdList) { - /*fprintf(stderr, "FilterSearchProc found %s\n", - Tcl_GetCommandName(interp, (Tcl_Command)cmdList->cmdPtr));*/ - if (Tcl_Command_cmdEpoch(cmdList->cmdPtr)) { - cmdList = cmdList->nextPtr; - } else if (FilterActiveOnObj(interp, object, cmdList->cmdPtr)) { - /* fprintf(stderr, "Filter <%s> -- Active on: %s\n", - Tcl_GetCommandName(interp, (Tcl_Command)cmdList->cmdPtr), ObjectName(object)); - */ - object->filterStack->currentCmdPtr = cmdList->cmdPtr; - cmdList = SeekCurrent(object->filterStack->currentCmdPtr, object->filterOrder); - } else { - /* ok. we found it */ - if (cmdList->clorobj && !NsfObjectIsClass(&cmdList->clorobj->object)) { - *clPtr = NULL; + *currentCmd = NULL; + cmdList = SeekCurrent(object->filterStack->currentCmdPtr, object->filterOrder); + + while (cmdList) { + /*fprintf(stderr, "FilterSearchProc found %s\n", + Tcl_GetCommandName(interp, (Tcl_Command)cmdList->cmdPtr));*/ + if (Tcl_Command_cmdEpoch(cmdList->cmdPtr)) { + cmdList = cmdList->nextPtr; + } else if (FilterActiveOnObj(interp, object, cmdList->cmdPtr)) { + /* fprintf(stderr, "Filter <%s> -- Active on: %s\n", + Tcl_GetCommandName(interp, (Tcl_Command)cmdList->cmdPtr), ObjectName(object)); + */ + object->filterStack->currentCmdPtr = cmdList->cmdPtr; + cmdList = SeekCurrent(object->filterStack->currentCmdPtr, object->filterOrder); } else { - *clPtr = cmdList->clorobj; + /* ok. we found it */ + if (cmdList->clorobj && !NsfObjectIsClass(&cmdList->clorobj->object)) { + *clPtr = NULL; + } else { + *clPtr = cmdList->clorobj; + } + *currentCmd = cmdList->cmdPtr; + /* fprintf(stderr, "FilterSearchProc - found: %s, %p\n", + Tcl_GetCommandName(interp, (Tcl_Command)cmdList->cmdPtr), cmdList->cmdPtr); + */ + return cmdList->cmdPtr; } - *currentCmd = cmdList->cmdPtr; - /* fprintf(stderr, "FilterSearchProc - found: %s, %p\n", - Tcl_GetCommandName(interp, (Tcl_Command)cmdList->cmdPtr), cmdList->cmdPtr); - */ - return cmdList->cmdPtr; } } return NULL; @@ -23729,11 +23731,11 @@ if (cl) { result = NsfAddClassMethod(interp, (Nsf_Class *)cl, methodName, - objProc, tcd, deleteProc, flags); + objProc, tcd, deleteProc, flags); nsPtr = cl->nsPtr; } else { result = NsfAddObjectMethod(interp, (Nsf_Object *)object, methodName, - objProc, tcd, deleteProc, flags); + objProc, tcd, deleteProc, flags); nsPtr = object->nsPtr; } Index: library/xotcl/tests/xocomm.test =================================================================== diff -u -r4bc60e16c10fdbbb640b3019d4bdebdc469fdf55 -rb4ed9a3212e6dbbd3275c3666ea2e738816594b0 --- library/xotcl/tests/xocomm.test (.../xocomm.test) (revision 4bc60e16c10fdbbb640b3019d4bdebdc469fdf55) +++ library/xotcl/tests/xocomm.test (.../xocomm.test) (revision b4ed9a3212e6dbbd3275c3666ea2e738816594b0) @@ -1,7 +1,7 @@ # -*- Tcl -*- package prefer latest package require XOTcl 2.0; namespace import ::xotcl::* -lappend auto_path [file dirname [info script]]/../library +set auto_path [concat [file dirname [info script]]/../library $auto_path] package require nx::test @ @File {