Fix ^D when not at the beginning of a line