From 96686fc9cebc1e452a7e6b1fd2c2b739c7603577 Mon Sep 17 00:00:00 2001 From: Martin Schanzenbach Date: Sun, 24 Jan 2016 12:39:50 +0000 Subject: - sscanf type fix --- src/identity-provider/identity_token.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/identity-provider/identity_token.c') diff --git a/src/identity-provider/identity_token.c b/src/identity-provider/identity_token.c index 41731bbf4..958597630 100644 --- a/src/identity-provider/identity_token.c +++ b/src/identity-provider/identity_token.c @@ -28,6 +28,7 @@ #include "gnunet_signatures.h" #include "identity_token.h" #include +#include #define JWT_ALG "alg" @@ -628,7 +629,7 @@ ticket_payload_serialize (struct TokenTicketPayload *payload, sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey)); GNUNET_asprintf (result, - "{\"nonce\": \"%lu\",\"identity\": \"%s\",\"label\": \"%s\"}", + "{\"nonce\": \""SCNu64"\",\"identity\": \"%s\",\"label\": \"%s\"}", payload->nonce, identity_key_str, payload->label); GNUNET_free (identity_key_str); @@ -818,7 +819,7 @@ ticket_payload_parse(const char *raw_data, nonce_str = json_string_value (nonce_json); GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Found nonce: %s\n", nonce_str); - GNUNET_assert (0 != sscanf (nonce_str, "%lu", &nonce)); + GNUNET_assert (0 != sscanf (nonce_str, "%"SCNu64, &nonce)); *result = ticket_payload_create (nonce, (const struct GNUNET_CRYPTO_EcdsaPublicKey*)&id_pkey, -- cgit v1.2.3