Bug fix for cutting folded lines at the end of the line.