Implemented compression for LzmaStream.
Lots of bug fixes and some clean up.