incorrect offset returned on write() after close()/open() [closes #4]