Normalize lines so un-terminated strings can be passed in (e.g. from Ruby source)