diff options
author | Christian Grothoff <christian@grothoff.org> | 2017-11-05 22:12:10 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2017-11-05 22:12:18 +0100 |
commit | 5295856396dc8364bf5ba3c710fb5210c095198a (patch) | |
tree | c743a3d31e3e32274187633afee4f6144ad1d685 /src/json/json_generator.c | |
parent | 9833b07bfe99df292b94847eadb086e7be9d5a72 (diff) | |
download | gnunet-5295856396dc8364bf5ba3c710fb5210c095198a.tar.gz gnunet-5295856396dc8364bf5ba3c710fb5210c095198a.zip |
add json from abs_time_nbo
Diffstat (limited to 'src/json/json_generator.c')
-rw-r--r-- | src/json/json_generator.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/json/json_generator.c b/src/json/json_generator.c index e660e10c5..98f7163bc 100644 --- a/src/json/json_generator.c +++ b/src/json/json_generator.c | |||
@@ -73,6 +73,19 @@ GNUNET_JSON_from_time_abs (struct GNUNET_TIME_Absolute stamp) | |||
73 | 73 | ||
74 | 74 | ||
75 | /** | 75 | /** |
76 | * Convert absolute timestamp to a json string. | ||
77 | * | ||
78 | * @param stamp the time stamp | ||
79 | * @return a json string with the timestamp in @a stamp | ||
80 | */ | ||
81 | json_t * | ||
82 | GNUNET_JSON_from_time_abs_nbo (struct GNUNET_TIME_AbsoluteNBO stamp) | ||
83 | { | ||
84 | return GNUNET_JSON_from_time_abs (GNUNET_TIME_absolute_ntoh (stamp)); | ||
85 | } | ||
86 | |||
87 | |||
88 | /** | ||
76 | * Convert relative timestamp to a json string. | 89 | * Convert relative timestamp to a json string. |
77 | * | 90 | * |
78 | * @param stamp the time stamp | 91 | * @param stamp the time stamp |