判断Module已经被释放时,再次释放会出现空情况

This commit is contained in:
boyce
2019-07-31 11:44:03 +08:00
parent 5724f80476
commit c11f8a07e4

View File

@@ -163,6 +163,10 @@ func (slf *BaseModule) ReleaseModule(moduleId uint32) bool {
//locker := slf.GetRoot().getBaseModule().getLocker()
locker := baseModule.getLocker()
if locker == nil {
return false
}
locker.Lock()
slf.releaseModule(moduleId)
locker.Unlock()