'utility function to decompress gzip compressed content'

def decompressGzipContent(self, httpcontent):

    cstr = cStringIO.StringIO(httpcontent)
    try:
        return gzip.GzipFile(fileobj=cstr).read()
    except:
        return None
