summaryrefslogtreecommitdiff
path: root/src/util/json.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2015-07-08 08:54:55 +0200
committerChristian Grothoff <christian@grothoff.org>2015-07-08 08:54:55 +0200
commit296e27b92ab0367f414dc0e98b185531c8df06f3 (patch)
tree9f2432f73e4d6018a7d4ecfada3e60096e015c40 /src/util/json.c
parentb7e2e107126cbd19aff063633c6d91029552e5d0 (diff)
downloadexchange-296e27b92ab0367f414dc0e98b185531c8df06f3.tar.gz
exchange-296e27b92ab0367f414dc0e98b185531c8df06f3.tar.bz2
exchange-296e27b92ab0367f414dc0e98b185531c8df06f3.zip
-simplify parsing, make code compile without new util API
Diffstat (limited to 'src/util/json.c')
-rw-r--r--src/util/json.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/util/json.c b/src/util/json.c
index 42f146463..e4b0831a4 100644
--- a/src/util/json.c
+++ b/src/util/json.c
@@ -291,11 +291,11 @@ TALER_json_to_amount (json_t *json,
memset (r_amount,
0,
sizeof (struct TALER_Amount));
- if (-1 == json_unpack (json,
- "{s:I, s:I, s:s}",
- "value", &value,
- "fraction", &fraction,
- "currency", &currency))
+ if (0 != json_unpack (json,
+ "{s:I, s:I, s:s}",
+ "value", &value,
+ "fraction", &fraction,
+ "currency", &currency))
{
GNUNET_break_op (0);
return GNUNET_SYSERR;