accounting: add context to Account and propagate changes #3257

This is preparation for getting the Accounting to check the context,
buf first we need to get it in place. Since this is one of those
changes that makes lots of noise, this is in a seperate commit.
This commit is contained in:
Nick Craig-Wood
2020-07-28 16:41:17 +01:00
parent 0bab9903ee
commit 421585dd72
9 changed files with 34 additions and 29 deletions
+1 -1
View File
@@ -495,7 +495,7 @@ func (dl *downloader) open(offset int64) (err error) {
if err != nil {
return errors.Wrap(err, "vfs reader: failed to open source file")
}
dl.in = dl.tr.Account(in0).WithBuffer() // account and buffer the transfer
dl.in = dl.tr.Account(dl.dls.ctx, in0).WithBuffer() // account and buffer the transfer
dl.offset = offset