Skip to content

Commit 6bd903e

Browse files
authored
fix: \r escape for libreoffice (#17)
1 parent 875b618 commit 6bd903e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

docx-core/src/escape/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,6 @@ pub(crate) fn escape(text: &str) -> String {
55
.replace('"', """)
66
.replace('\'', "'")
77
.replace('\n', "
")
8+
// If \r escape to &#xD, this cause error in libreoffice
89
.replace('\r', "
")
910
}

0 commit comments

Comments
 (0)