PK11_ClearSlotList(module->slots[i]);
PK11_ClearSlotList(module->slots[i]); if (module->slots[i]->nssToken) { nssToken_NotifyCertsNotVisible(module->slots[i]->nssToken); }
SECMOD_DestroyModule(SECMODModule *module) {    PRBool willfree = PR_FALSE;    int slotCount;    int i;    PK11_USE_THREADS(PZ_Lock((PZLock *)module->refLock);)    if (module->refCount-- == 1) {	willfree = PR_TRUE;    }    PORT_Assert(willfree || (module->refCount > 0));    PK11_USE_THREADS(PZ_Unlock((PZLock *)module->refLock);)    if (!willfree) {	return;    }       if (module->parent != NULL) {	SECMODModule *parent = module->parent;	/* paranoia, don't loop forever if the modules are looped */	module->parent = NULL;	SECMOD_DestroyModule(parent);    }    /* slots can't really disappear until our module starts freeing them,     * so this check is safe */    slotCount = module->slotCount;    if (slotCount == 0) {	SECMOD_SlotDestroyModule(module,PR_FALSE);	return;    }    /* now free all out slots, when they are done, they will cause the     * module to disappear altogether */    for (i=0 ; i < slotCount; i++) {	if (!module->slots[i]->disabled) {		PK11_ClearSlotList(module->slots[i]);	}	PK11_FreeSlot(module->slots[i]);    }    /* WARNING: once the last slot has been freed is it possible (even likely)     * that module is no more... touching it now is a good way to go south */}