fixed few bugs in PersistentLongFile