Ensured putc instruction will properly close file handles