rembish/cfb — pull request #4 by molnarg (2014-01-16 17:03:27+00:00)
Title: Fix minifat problems

This commit fixes two problems. The first is a simple typo in cfb/__init__.py.

The second problem is that when using two minifat based entry or a minifat based entry and the root entry in parallel, the minifat entry's read method reads data from unappropriate position. The root of the problem is that `read()` does not restore the cursor position of the root entry before reading (just the source position, which, in this case is different). The proper fix would probably be changing the `self._source_position` variable to `self._stream_position` and always using it on `self.stream`, but that somehow did not work, so this patch seeks to the current position before every read from minifat entries.