Browse Source

Fix \r and \n not supported in JSON value

pull/202/head
terry-xiaoyu 4 years ago
parent
commit
0fea4857b6
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      c_src/decoder.c

+ 1
- 1
c_src/decoder.c View File

@ -208,7 +208,7 @@ dec_string(Decoder* d, ERL_NIF_TERM* value)
st = d->i;
while(d->i < d->len) {
if(d->p[d->i] < 0x20) {
if((d->p[d->i] < 0x20) && (d->p[d->i] != 10) && (d->p[d->i] != 13)) {
return 0;
} else if(d->p[d->i] == '\"') {
d->i++;

Loading…
Cancel
Save