[Pkg-privacy-commits] [torbrowser-launcher] 12/476: it now saves the tbb tarball to file
Ximin Luo
infinity0 at moszumanska.debian.org
Sat Aug 22 13:21:18 UTC 2015
This is an automated email from the git hooks/post-receive script.
infinity0 pushed a commit to branch debian
in repository torbrowser-launcher.
commit 338d2d5ac424b611eade4a8bee959c7ddbac8268
Author: Micah Lee <micahflee at riseup.net>
Date: Fri Feb 8 18:29:14 2013 -0800
it now saves the tbb tarball to file
---
torbrowser-launcher | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/torbrowser-launcher b/torbrowser-launcher
index 1b61e66..89f6801 100755
--- a/torbrowser-launcher
+++ b/torbrowser-launcher
@@ -10,8 +10,10 @@ def download_chunk(base):
# download 8192 bytes a time
chunk = base.dl_response.read(8192)
base.dl_bytes_so_far += len(chunk)
+ base.tarball_file.write(chunk)
if not chunk:
+ base.tarball_file.close()
return False
percent = float(base.dl_bytes_so_far) / base.dl_total_size
@@ -57,6 +59,9 @@ class Base:
# set a timer to download more chunks
self.timer = gobject.timeout_add(10, download_chunk, self)
+
+ # open a file to write to
+ self.tarball_file = open(self.tarball_path, 'w')
def __init__(self, tbb_version, tarball_path, tarball_url):
self.timer = False
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/torbrowser-launcher.git
More information about the Pkg-privacy-commits
mailing list