libadlin: fix panic on return due to mutex
This commit is contained in:
parent
8c53414477
commit
5542804b21
|
@ -66,6 +66,8 @@ func readWgDump() (wgd map[string]WGDump, err error) {
|
|||
if time.Since(wgDumpCache_time) > time.Second*10 {
|
||||
wgd, err = _readWgDump()
|
||||
if err != nil {
|
||||
wgDumpCache_mutex.Unlock()
|
||||
wgDumpCache_mutex.RLock()
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Reference in New Issue