Index: TODO =================================================================== diff -u -r570b3538965101b43ca08cf3c23a3acd826c14df -rb41aa0b8fa5782016df832c2ce08a7aab5681dc2 --- TODO (.../TODO) (revision 570b3538965101b43ca08cf3c23a3acd826c14df) +++ TODO (.../TODO) (revision b41aa0b8fa5782016df832c2ce08a7aab5681dc2) @@ -2246,8 +2246,11 @@ we switched from approach 1 to approach 3 - extended regression test +- fixed potential crash with missing parent namespace + TODO: + - object parameter type forward: - regression test - reduce verbosity Index: generic/nsf.c =================================================================== diff -u -rbc85b3848186ff8269496f53c45255a11c556f53 -rb41aa0b8fa5782016df832c2ce08a7aab5681dc2 --- generic/nsf.c (.../nsf.c) (revision bc85b3848186ff8269496f53c45255a11c556f53) +++ generic/nsf.c (.../nsf.c) (revision b41aa0b8fa5782016df832c2ce08a7aab5681dc2) @@ -3498,13 +3498,13 @@ static int NSRequireParentObject(Tcl_Interp *interp, CONST char *parentName, NsfClass *cl) { NsfClass *defaultSuperClass = DefaultSuperClass(interp, cl, cl->object.cl, 1); - Tcl_Obj *methodObj = NsfMethodObj(&defaultSuperClass->object, NSF_c_requireobject_idx); + Tcl_Obj *methodObj; int rc = 0; - /*fprintf(stderr, "NSRequireParentObject %s cl %p (%s) methodObj %p defaultSc %p %s\n", - parentName, cl, ClassName(cl), methodObj, defaultSuperClass, ClassName(defaultSuperClass));*/ + /*fprintf(stderr, "NSRequireParentObject %s cl %p (%s) defaultSc %p %s\n", + parentName, cl, ClassName(cl), defaultSuperClass, ClassName(defaultSuperClass));*/ - if (methodObj) { + if (defaultSuperClass && (methodObj = NsfMethodObj(&defaultSuperClass->object, NSF_c_requireobject_idx))) { /* call requireObject and try again */ Tcl_Obj *ov[3]; int result;