Got serial compression and decompression to work correctly for most files