added a new method for making a nonstupid ObjectInputStream