File tree Expand file tree Collapse file tree 2 files changed +4
-0
lines changed
Expand file tree Collapse file tree 2 files changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -119,6 +119,8 @@ object (self)
119119 if Char. code s.[offset + len] = 0 then
120120 let str = String. sub s offset len in
121121 let new_s = string_replace '\n' " \\ n" str in
122+ let new_s = string_replace '\r' " \\ r" new_s in
123+ let new_s = string_replace '"' " \\\" " new_s in
122124 begin
123125 string_table#add_string va new_s;
124126 Some new_s
Original file line number Diff line number Diff line change @@ -87,6 +87,8 @@ object (self)
8787 if Char. code s.[offset+ len] = 0 then
8888 let str = String. sub s offset len in
8989 let new_s = string_replace '\n' " \\ n" str in
90+ let new_s = string_replace '\r' " \\ r" new_s in
91+ let new_s = string_replace '"' " \\\" " new_s in
9092 begin
9193 string_table#add_string va new_s ;
9294 Some new_s
You can’t perform that action at this time.
0 commit comments