mirror of
https://github.com/johnwhitington/cpdf-source.git
synced 2025-02-03 11:58:01 +01:00
Octal digits go 0..7 not 0..9!
This commit is contained in:
parent
26378caeff
commit
25668ecfe8
2
cpdf.ml
2
cpdf.ml
@ -1698,7 +1698,7 @@ let split_at_newline t =
|
||||
|
||||
let rec unescape_chars prev = function
|
||||
| [] -> rev prev
|
||||
| '\\'::('0'..'9' as a)::('0'..'9' as b)::('0'..'9' as c)::t ->
|
||||
| '\\'::('0'..'7' as a)::('0'..'7' as b)::('0'..'7' as c)::t ->
|
||||
let chr = char_of_int (int_of_string ("0o" ^ implode [a;b;c])) in
|
||||
unescape_chars (chr::prev) t
|
||||
| '\\'::'\\'::t -> unescape_chars ('\\'::prev) t
|
||||
|
Loading…
x
Reference in New Issue
Block a user