Fixed fail override tmp code file.

Signed-off-by: Kouhei Maeda <mkouhei@palmtb.net>
Fixed deadlock occurs when typing Ctrl+D immediately after gosh start.

Signed-off-by: Kouhei Maeda <mkouhei@palmtb.net>