mirror of
https://github.com/duanhf2012/origin.git
synced 2026-03-05 13:47:35 +08:00
判断Module已经被释放时,再次释放会出现空情况
This commit is contained in:
@@ -163,6 +163,10 @@ func (slf *BaseModule) ReleaseModule(moduleId uint32) bool {
|
|||||||
|
|
||||||
//locker := slf.GetRoot().getBaseModule().getLocker()
|
//locker := slf.GetRoot().getBaseModule().getLocker()
|
||||||
locker := baseModule.getLocker()
|
locker := baseModule.getLocker()
|
||||||
|
if locker == nil {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
locker.Lock()
|
locker.Lock()
|
||||||
slf.releaseModule(moduleId)
|
slf.releaseModule(moduleId)
|
||||||
locker.Unlock()
|
locker.Unlock()
|
||||||
|
|||||||
Reference in New Issue
Block a user