Last missing bit of Popen

This commit is contained in:
Daniel Martí 2014-01-27 16:31:11 +01:00
parent 62c3663df3
commit c7f2cbd85b

View file

@ -25,9 +25,10 @@ import traceback
import glob
from optparse import OptionParser
import paramiko
import common, metadata
import socket
import subprocess
import common, metadata
from common import FDroidPopen
def carbon_send(key, value):
s = socket.socket()
@ -121,12 +122,13 @@ def main():
for logfile in glob.glob(os.path.join(logsdir,'access-*.log.gz')):
if options.verbose:
print '...' + logfile
p = subprocess.Popen(["zcat", logfile], stdout = subprocess.PIPE)
p = FDroidPopen(["zcat", logfile])
matches = (logsearch(line) for line in p.stdout)
for match in matches:
if match and match.group('statuscode') == '200':
uri = match.group('uri')
if uri.endswith('.apk'):
if not uri.endswith('.apk'):
continue
_, apkname = os.path.split(uri)
app = knownapks.getapp(apkname)
if app: