summaryrefslogtreecommitdiff
path: root/json-glib/json-parser.c
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2009-08-12 15:56:00 +0100
committerEmmanuele Bassi <ebassi@gnome.org>2009-08-12 15:56:00 +0100
commit9a647104ca77d4c4272845fed4bfae028098afd3 (patch)
tree747ce092e9562ac55ac4dce8ee67926395399380 /json-glib/json-parser.c
parentf3e0618ee1d8aa90d0ba22e9abe5c7d6b849e0ea (diff)
downloadjson-glib-9a647104ca77d4c4272845fed4bfae028098afd3.tar.gz
Actually use the int64 support in the Scanner
We switched everything to 64 bit integers but then I forgot to enable the support for actually making the tokenizer store the parsed integers into a 64 bit value. Bad Emmanuele, no cookie for you.
Diffstat (limited to 'json-glib/json-parser.c')
-rw-r--r--json-glib/json-parser.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/json-glib/json-parser.c b/json-glib/json-parser.c
index 1da6951..accf876 100644
--- a/json-glib/json-parser.c
+++ b/json-glib/json-parser.c
@@ -470,8 +470,8 @@ json_parse_array (JsonParser *parser,
{
case G_TOKEN_INT:
node = json_node_new (JSON_NODE_VALUE);
- json_node_set_int (node, negative ? scanner->value.v_int * -1
- : scanner->value.v_int);
+ json_node_set_int (node, negative ? scanner->value.v_int64 * -1
+ : scanner->value.v_int64);
break;
case G_TOKEN_FLOAT:
@@ -699,8 +699,8 @@ json_parse_object (JsonParser *parser,
{
case G_TOKEN_INT:
node = json_node_new (JSON_NODE_VALUE);
- json_node_set_int (node, negative ? scanner->value.v_int * -1
- : scanner->value.v_int);
+ json_node_set_int (node, negative ? scanner->value.v_int64 * -1
+ : scanner->value.v_int64);
break;
case G_TOKEN_FLOAT:
@@ -843,7 +843,7 @@ json_parse_statement (JsonParser *parser,
{
case G_TOKEN_INT:
json_node_set_int (priv->current_node,
- scanner->value.v_int * -1);
+ scanner->value.v_int64 * -1);
break;
case G_TOKEN_FLOAT:
json_node_set_double (priv->current_node,
@@ -867,7 +867,7 @@ json_parse_statement (JsonParser *parser,
priv->root = priv->current_node = json_node_new (JSON_NODE_VALUE);
if (token == G_TOKEN_INT)
- json_node_set_int (priv->current_node, scanner->value.v_int);
+ json_node_set_int (priv->current_node, scanner->value.v_int64);
else if (token == G_TOKEN_FLOAT)
json_node_set_double (priv->current_node, scanner->value.v_float);
else