Skip to content

Commit

Permalink
gridstore: close write channels before end
Browse files Browse the repository at this point in the history
  • Loading branch information
DocSavage committed Nov 29, 2024
1 parent 1dd86eb commit 44df7b0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions datatype/imageblk/imageblk.go
Original file line number Diff line number Diff line change
Expand Up @@ -1930,6 +1930,7 @@ func (d *Data) SendGridBlocks(w http.ResponseWriter, blockCoords []dvid.ChunkPoi
}
writeCh <- &storage.Block{Coord: blockCoord, Value: value}
}
close(writeCh)
writeWg.Wait()
return nil
}
Expand Down Expand Up @@ -1962,6 +1963,7 @@ func (d *Data) SendGridVolume(w http.ResponseWriter, subvol *dvid.Subvolume, gri
}
return nil
})
close(writeCh)
writeWg.Wait()
return err
}
Expand Down

0 comments on commit 44df7b0

Please sign in to comment.