chiark / gitweb /
shared: json - support escaping utf16 surrogate pairs
authorTom Gundersen <teg@jklm.no>
Mon, 22 Dec 2014 13:53:40 +0000 (14:53 +0100)
committerTom Gundersen <teg@jklm.no>
Mon, 22 Dec 2014 19:27:20 +0000 (20:27 +0100)
commit9bae67d49b861b1f142f1a1e27753fe08e63ade7
tree8e3b1d2d0c34558b17344526923697f5ea382c8d
parent04166cb7dd90918385835f246c43d8ec22af0d68
shared: json - support escaping utf16 surrogate pairs

We originally only supported escaping ucs2 encoded characters (as \uxxxx). This
only covers the BMP. Support escaping also utf16 surrogate pairs (on the form
\uxxxx\uyyyy) to cover all of unicode.
src/shared/json.c
src/test/test-json.c