~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/knit.py

  • Committer: Andrew Bennetts
  • Date: 2011-02-07 04:14:29 UTC
  • mfrom: (5535.4.26 fetch-all-tags-309682)
  • mto: This revision was merged to the branch mainline in revision 5648.
  • Revision ID: andrew.bennetts@canonical.com-20110207041429-3kc1blj34rvvxod9
Merge fetch-all-tags-309682.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2006-2010 Canonical Ltd
 
1
# Copyright (C) 2006-2011 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
54
54
 
55
55
from cStringIO import StringIO
56
56
from itertools import izip
 
57
import gzip
57
58
import operator
58
59
import os
59
60
import sys
1879
1880
        :return: the header and the decompressor stream.
1880
1881
                 as (stream, header_record)
1881
1882
        """
1882
 
        df = tuned_gzip.GzipFile(mode='rb', fileobj=StringIO(raw_data))
 
1883
        df = gzip.GzipFile(mode='rb', fileobj=StringIO(raw_data))
1883
1884
        try:
1884
1885
            # Current serialise
1885
1886
            rec = self._check_header(key, df.readline())
1894
1895
        # 4168 calls in 2880 217 internal
1895
1896
        # 4168 calls to _parse_record_header in 2121
1896
1897
        # 4168 calls to readlines in 330
1897
 
        df = tuned_gzip.GzipFile(mode='rb', fileobj=StringIO(data))
 
1898
        df = gzip.GzipFile(mode='rb', fileobj=StringIO(data))
1898
1899
        try:
1899
1900
            record_contents = df.readlines()
1900
1901
        except Exception, e: