Fix bogus assert. 0x10ffff is a valid code point
This commit is contained in:
@@ -571,7 +571,7 @@ inline PRESERVE_NONE WeaselJsonStatus n_string2(Parser3 *self, char *buf,
|
|||||||
return WeaselJson_REJECT;
|
return WeaselJson_REJECT;
|
||||||
}
|
}
|
||||||
buf += 6;
|
buf += 6;
|
||||||
assert(codepoint < 0x10ffff);
|
assert(codepoint <= 0x10ffff);
|
||||||
self->writeBuf[3] = (0b00111111 & codepoint) | 0b10000000;
|
self->writeBuf[3] = (0b00111111 & codepoint) | 0b10000000;
|
||||||
codepoint >>= 6;
|
codepoint >>= 6;
|
||||||
self->writeBuf[2] = (0b00111111 & codepoint) | 0b10000000;
|
self->writeBuf[2] = (0b00111111 & codepoint) | 0b10000000;
|
||||||
|
|||||||
Reference in New Issue
Block a user