Index: generic/nsf.c =================================================================== diff -u -r5163190ade6f6a2abcd8b7f0265f74457557a61c -r36b29a9f1f308d692dc1b4ce35c4adb0948bd6bd --- generic/nsf.c (.../nsf.c) (revision 5163190ade6f6a2abcd8b7f0265f74457557a61c) +++ generic/nsf.c (.../nsf.c) (revision 36b29a9f1f308d692dc1b4ce35c4adb0948bd6bd) @@ -427,7 +427,6 @@ static int MethodSourceMatches(int withSource, NsfClass *cl, NsfObject *object); static NsfObjectOpt *NsfRequireObjectOpt(NsfObject *object) nonnull(1) returns_nonnull; -static NsfClassOpt * NsfRequireClassOpt(/*@notnull@*/ NsfClass *cl) nonnull(1) returns_nonnull; static int ObjectSystemsCheckSystemMethod(Tcl_Interp *interp, CONST char *methodName, NsfObject *object, unsigned int flags) @@ -4148,7 +4147,7 @@ } -static NsfClassOpt * +NsfClassOpt * NsfRequireClassOpt(/*@notnull@*/ NsfClass *cl) { assert(cl); @@ -18724,16 +18723,24 @@ } } - if (clopt) { + if (clopt != NULL) { /* * Remove this class from all isClassMixinOf lists and clear the * class mixin list */ - if (clopt->classMixins) RemoveFromClassMixinsOf(clopt->id, clopt->classMixins); + if (clopt->classMixins) { + RemoveFromClassMixinsOf(clopt->id, clopt->classMixins); + } CmdListFree(&clopt->classMixins, GuardDel); CmdListFree(&clopt->classFilters, GuardDel); + if (clopt->mixinRegObjs != NULL) { + NsfMixinregInvalidate(interp, clopt->mixinRegObjs); + DECR_REF_COUNT2("mixinRegObjs", clopt->mixinRegObjs); + clopt->mixinRegObjs = NULL; + } + if (!recreate) { /* * Remove this class from all mixin lists and clear the isObjectMixinOf list @@ -18805,9 +18812,9 @@ MEM_COUNT_FREE("Tcl_InitHashTable", &cl->instances); } - if ((clopt) && (!recreate)) { + if (clopt != NULL && recreate == 0) { FREE(NsfClassOpt, clopt); - cl->opt = 0; + cl->opt = NULL; } if (subClasses) { @@ -26770,8 +26777,8 @@ int canFree; } NsfParamWrapper; -static Tcl_DupInternalRepProc ParamDupInteralRep; -static Tcl_FreeInternalRepProc ParamFreeInternalRep; +static Tcl_DupInternalRepProc ParamDupInteralRep; +static Tcl_FreeInternalRepProc ParamFreeInternalRep; static Tcl_UpdateStringProc ParamUpdateString; static void ParamUpdateString(Tcl_Obj *objPtr) nonnull(1);