fix prematured file error