read and minor fixes