Merge pull request #199 from tonistiigi/mutable-race
cache: fix race on reloading mutablerefdocker-18.09
commit
d813f6c08d
|
@ -117,7 +117,7 @@ func (cm *cacheManager) get(ctx context.Context, id string, opts ...RefOption) (
|
|||
}
|
||||
|
||||
func (cm *cacheManager) load(ctx context.Context, id string, opts ...RefOption) (*cacheRecord, error) {
|
||||
if rec, ok := cm.records[id]; ok {
|
||||
if rec, ok := cm.records[id]; ok && !rec.dead {
|
||||
return rec, nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue