mirror of
https://github.com/octoleo/restic.git
synced 2024-11-26 14:56:29 +00:00
repository: cleanup
This commit is contained in:
parent
c1a8fa4290
commit
2cd7e90ad1
@ -243,13 +243,10 @@ func (mi *MasterIndex) Each(ctx context.Context) <-chan restic.PackedBlob {
|
|||||||
|
|
||||||
go func() {
|
go func() {
|
||||||
defer mi.idxMutex.RUnlock()
|
defer mi.idxMutex.RUnlock()
|
||||||
defer func() {
|
defer close(ch)
|
||||||
close(ch)
|
|
||||||
}()
|
|
||||||
|
|
||||||
for _, idx := range mi.idx {
|
for _, idx := range mi.idx {
|
||||||
idxCh := idx.Each(ctx)
|
for pb := range idx.Each(ctx) {
|
||||||
for pb := range idxCh {
|
|
||||||
select {
|
select {
|
||||||
case <-ctx.Done():
|
case <-ctx.Done():
|
||||||
return
|
return
|
||||||
|
Loading…
Reference in New Issue
Block a user