aboutsummaryrefslogtreecommitdiff
path: root/src/util/json.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/util/json.c')
-rw-r--r--src/util/json.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/util/json.c b/src/util/json.c
index 252def394..f686d84a1 100644
--- a/src/util/json.c
+++ b/src/util/json.c
@@ -13,13 +13,11 @@
13 You should have received a copy of the GNU General Public License along with 13 You should have received a copy of the GNU General Public License along with
14 TALER; see the file COPYING. If not, If not, see <http://www.gnu.org/licenses/> 14 TALER; see the file COPYING. If not, If not, see <http://www.gnu.org/licenses/>
15*/ 15*/
16
17/** 16/**
18 * @file util/json.c 17 * @file util/json.c
19 * @brief helper functions for JSON processing using libjansson 18 * @brief helper functions for JSON processing using libjansson
20 * @author Sree Harsha Totakura <sreeharsha@totakura.in> 19 * @author Sree Harsha Totakura <sreeharsha@totakura.in>
21 */ 20 */
22
23#include "platform.h" 21#include "platform.h"
24#include <gnunet/gnunet_util_lib.h> 22#include <gnunet/gnunet_util_lib.h>
25#include "taler_util.h" 23#include "taler_util.h"
@@ -49,6 +47,7 @@
49 if (cond) { WARN_JSON(error); goto EXITIF_exit; } \ 47 if (cond) { WARN_JSON(error); goto EXITIF_exit; } \
50 } while (0) 48 } while (0)
51 49
50
52/** 51/**
53 * Convert a TALER amount to a JSON 52 * Convert a TALER amount to a JSON
54 * object. 53 * object.
@@ -60,6 +59,7 @@ json_t *
60TALER_JSON_from_amount (struct TALER_Amount amount) 59TALER_JSON_from_amount (struct TALER_Amount amount)
61{ 60{
62 json_t *j; 61 json_t *j;
62
63 j = json_pack ("{s: s, s:I, s:I}", 63 j = json_pack ("{s: s, s:I, s:I}",
64 "currency", amount.currency, 64 "currency", amount.currency,
65 "value", (json_int_t) amount.value, 65 "value", (json_int_t) amount.value,