mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2024-12-29 17:28:53 +00:00
download.py: set up self._paused before registering the producer, since they might call pauseProducing right away
This commit is contained in:
parent
9e22353773
commit
cd4d3cdeea
@ -456,13 +456,13 @@ class FileDownloader:
|
|||||||
self._results.timings["cumulative_decrypt"] = 0.0
|
self._results.timings["cumulative_decrypt"] = 0.0
|
||||||
self._results.timings["paused"] = 0.0
|
self._results.timings["paused"] = 0.0
|
||||||
|
|
||||||
|
self._paused = False
|
||||||
|
self._stopped = False
|
||||||
if IConsumer.providedBy(downloadable):
|
if IConsumer.providedBy(downloadable):
|
||||||
downloadable.registerProducer(self, True)
|
downloadable.registerProducer(self, True)
|
||||||
self._downloadable = downloadable
|
self._downloadable = downloadable
|
||||||
self._output = Output(downloadable, u.key, self._size, self._log_number,
|
self._output = Output(downloadable, u.key, self._size, self._log_number,
|
||||||
self._status)
|
self._status)
|
||||||
self._paused = False
|
|
||||||
self._stopped = False
|
|
||||||
|
|
||||||
self.active_buckets = {} # k: shnum, v: bucket
|
self.active_buckets = {} # k: shnum, v: bucket
|
||||||
self._share_buckets = [] # list of (sharenum, bucket) tuples
|
self._share_buckets = [] # list of (sharenum, bucket) tuples
|
||||||
|
Loading…
Reference in New Issue
Block a user