Fixes line endings if \r\n is found

Need to append both \r\n in dos mode in order to not mess up line endings