Limit rac concurrent reader buffer sizes

This commit is contained in:
Nigel Tao committed 2019-09-01 15:09:56 +10:00
1 parent 396921817d
commit c3f45a7aed
3 files changed
+165 -93

No files matched your search

+3
View File
@@ -514,6 +514,9 @@ func (r *Reader) seek(offset int64, whence int, limit int64) (int64, error) {
// which may take some time. If the caller does not care about waiting until it
// is safe to close or otherwise release the r.ReadSeeker's resources, call
// CloseWithoutWaiting instead.
//
// It is not safe to call Close from a separate goroutine while another method
// call like Read or Seek is in progress.
func (r *Reader) Close() error {
if err := r.initialize(); err != nil {
r.concReader.Close()