Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d49faf8

Browse files
committed
ttconv: Also replace carriage return with spaces.
Multi-line strings will cause issues in comments since the secondary lines will not be comments. This replacement is already done for newline characters (\n), but not carriage return (\r) which is prevalent on Windows.
1 parent 75a35ef commit d49faf8

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

extern/ttconv/ttutil.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ void TTStreamWriter::putline(const char *a)
7676
void replace_newlines_with_spaces(char *a) {
7777
char* i = a;
7878
while (*i != 0) {
79-
if (*i == '\n')
79+
if (*i == '\r' || *i == '\n')
8080
*i = ' ';
8181
i++;
8282
}

0 commit comments

Comments
 (0)