Fix small bugs re. naming and EOF