• Andrew M. Kuchling's avatar
    Based on a suggestion from bruce@hams.com, make a trivial change to · f4f119c0
    Andrew M. Kuchling yazdı
    allow using the 'a' flag as a mode for opening a GzipFile.  gzip
    files, surprisingly enough, can be concatenated and then decompressed;
    the effect is to concatenate the two chunks of data.
    
    If we support it on writing, it should also be supported on reading.
    This *wasn't* trivial, and required rearranging the code in the
    reading path, particularly the _read() method.
    
    Raise IOError instead of RuntimeError in two cases, 'Not a gzipped file'
    and 'Unknown compression method'
    f4f119c0
gzip.py 10.7 KB