fix file read problem