Better way of fixing line endings