Skip to content

Commit

Permalink
Fixed deadlock when restarting (#157)
Browse files Browse the repository at this point in the history
  • Loading branch information
dylanratcliffe authored Jul 27, 2023
1 parent 8bd3d89 commit fa22173
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions sourcehost.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,8 @@ func (sh *SourceHost) ExpandQuery(q *sdp.Query) map[*sdp.Query][]Source {
// ClearAllSources Removes all sources
func (sh *SourceHost) ClearAllSources() {
sh.sourceMapMutex.Lock()
defer sh.sourceMapMutex.Unlock()

sh.sourceMap = make(map[string][]Source)
sh.sourceMapMutex.Unlock()

sh.addBuiltinSources()
}
Expand Down

0 comments on commit fa22173

Please sign in to comment.