summaryrefslogtreecommitdiffstats
path: root/src/jv_parse.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/jv_parse.c')
-rw-r--r--src/jv_parse.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/jv_parse.c b/src/jv_parse.c
index 110483a4..9755b8ac 100644
--- a/src/jv_parse.c
+++ b/src/jv_parse.c
@@ -514,7 +514,7 @@ static pfunc check_literal(struct jv_parser* p) {
case 'f': pattern = "false"; plen = 5; v = jv_false(); break;
case 'n':
// if it starts with 'n', it could be a literal "nan"
- if (p->tokenpos != 3) {
+ if (p->tokenbuf[1] == 'u') {
pattern = "null"; plen = 4; v = jv_null();
}
}