fix handling of no-break spaces at end of line