X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=daklib%2Futils.py;h=9582dadb997cd8646e6f5c706485036b8a0d7d67;hb=9af1235da5224336ede312fb5c3e0fe791bc19f0;hp=5e3627969f9b1f69cd8a216afe3b4dd49a5495c3;hpb=cd5b29ddfd8de263c085f494b9573d683913f6f3;p=dak.git diff --git a/daklib/utils.py b/daklib/utils.py index 5e362796..9582dadb 100755 --- a/daklib/utils.py +++ b/daklib/utils.py @@ -37,6 +37,7 @@ import stat import apt_pkg import database import time +import tarfile from dak_exceptions import * from regexes import re_html_escaping, html_escaping, re_single_line_field, \ re_multi_line_field, re_srchasver, re_verwithext, \ @@ -1468,7 +1469,7 @@ def generate_contents_information(filename): # and pieces the deb had ... if chunks[2] == "data.tar.gz": data = tarfile.open("data.tar.gz", "r:gz") - elif data_tar == "data.tar.bz2": + elif chunks[2] == "data.tar.bz2": data = tarfile.open("data.tar.bz2", "r:bz2") else: os.remove(chunks[2])