[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnunet] 11/31: uncrustify
From: |
gnunet |
Subject: |
[gnunet] 11/31: uncrustify |
Date: |
Wed, 22 Apr 2020 21:53:02 +0200 |
This is an automated email from the git hooks/post-receive script.
martin-schanzenbach pushed a commit to branch master
in repository gnunet.
commit c2127bac669d91eb66bea91f5a9e0b27106a9152
Author: Schanzenbach, Martin <address@hidden>
AuthorDate: Sun Apr 19 20:30:07 2020 +0200
uncrustify
---
src/revocation/gnunet-revocation.c | 2 +-
src/revocation/revocation_api.c | 16 +++++++++-------
2 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/src/revocation/gnunet-revocation.c
b/src/revocation/gnunet-revocation.c
index 2d83da8b6..16f62de9d 100644
--- a/src/revocation/gnunet-revocation.c
+++ b/src/revocation/gnunet-revocation.c
@@ -280,7 +280,7 @@ calculate_pow (void *cls)
/* store temporary results */
pow_task = NULL;
- //if (0 == (rd->pow % 128))
+ // if (0 == (rd->pow % 128))
// sync_rd (rd);
/* actually do POW calculation */
if (GNUNET_OK == GNUNET_REVOCATION_pow_round (ph))
diff --git a/src/revocation/revocation_api.c b/src/revocation/revocation_api.c
index bd0202b67..0361f239b 100644
--- a/src/revocation/revocation_api.c
+++ b/src/revocation/revocation_api.c
@@ -430,7 +430,8 @@ GNUNET_REVOCATION_check_pow (const struct
GNUNET_REVOCATION_Pow *pow,
*/
for (unsigned int i = 0; i < POW_COUNT; i++)
{
- for (unsigned int j = i+1; j < POW_COUNT; j++) {
+ for (unsigned int j = i + 1; j < POW_COUNT; j++)
+ {
if (pow->pow[i] == pow->pow[j])
return GNUNET_NO;
}
@@ -451,7 +452,7 @@ GNUNET_REVOCATION_check_pow (const struct
GNUNET_REVOCATION_Pow *pow,
&result);
tmp_score = count_leading_zeroes (&result);
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
- "Score %u with %"PRIu64" (#%u)\n",
+ "Score %u with %" PRIu64 " (#%u)\n",
tmp_score, pow_val, i);
score += tmp_score;
@@ -472,11 +473,11 @@ GNUNET_REVOCATION_pow_init (const struct
GNUNET_CRYPTO_EcdsaPublicKey *key,
unsigned int difficulty)
{
struct GNUNET_REVOCATION_PowCalculationHandle*pc;
- struct GNUNET_TIME_Absolute ts = GNUNET_TIME_absolute_get();
+ struct GNUNET_TIME_Absolute ts = GNUNET_TIME_absolute_get ();
pc = GNUNET_new (struct GNUNET_REVOCATION_PowCalculationHandle);
pc->pow.key = *key;
- pc->pow.timestamp = GNUNET_TIME_absolute_hton(ts);
+ pc->pow.timestamp = GNUNET_TIME_absolute_hton (ts);
pc->current_pow = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK,
UINT64_MAX);
pc->difficulty = difficulty;
@@ -533,7 +534,7 @@ GNUNET_REVOCATION_pow_round (struct
GNUNET_REVOCATION_PowCalculationHandle *pc)
pc->best[i].pow = pc->current_pow;
pc->pow.pow[i] = GNUNET_htonll (pc->current_pow);
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
- "New best score %u with %"PRIu64" (#%u)\n",
+ "New best score %u with %" PRIu64 " (#%u)\n",
zeros, pc->current_pow, i);
break;
}
@@ -568,11 +569,12 @@ GNUNET_REVOCATION_pow_cleanup (struct
*/
void
GNUNET_REVOCATION_sign_revocation (struct GNUNET_REVOCATION_Pow *pow,
- const struct GNUNET_CRYPTO_EcdsaPrivateKey
*key)
+ const struct
+ GNUNET_CRYPTO_EcdsaPrivateKey *key)
{
pow->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_REVOCATION);
pow->purpose.size = htonl (sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose)
- + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey));
+ + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey));
GNUNET_CRYPTO_ecdsa_key_get_public (key, &pow->key);
GNUNET_assert (GNUNET_OK ==
GNUNET_CRYPTO_ecdsa_sign_ (key,
--
To stop receiving notification emails like this one, please contact
address@hidden.
- [gnunet] branch master updated (bf99d2243 -> f225e5688), gnunet, 2020/04/22
- [gnunet] 04/31: merge, gnunet, 2020/04/22
- [gnunet] 01/31: add argon2 for LSD0001, gnunet, 2020/04/22
- [gnunet] 03/31: update params, gnunet, 2020/04/22
- [gnunet] 02/31: add argon2 for LSD0001, gnunet, 2020/04/22
- [gnunet] 07/31: towards more expirations, gnunet, 2020/04/22
- [gnunet] 05/31: revert, gnunet, 2020/04/22
- [gnunet] 06/31: simplify pow even more; add timestamp to revocation pow, gnunet, 2020/04/22
- [gnunet] 09/31: no diplicate nonces, gnunet, 2020/04/22
- [gnunet] 11/31: uncrustify,
gnunet <=
- [gnunet] 12/31: those are actually debug messages, gnunet, 2020/04/22
- [gnunet] 13/31: more comments, allow to pick up pow later, gnunet, 2020/04/22
- [gnunet] 18/31: fix, gnunet, 2020/04/22
- [gnunet] 10/31: some comments, gnunet, 2020/04/22
- [gnunet] 25/31: packed makes no sense there, gnunet, 2020/04/22
- [gnunet] 19/31: check signature in check_pow, gnunet, 2020/04/22
- [gnunet] 14/31: evaluate epochs, gnunet, 2020/04/22
- [gnunet] 24/31: remove pow_get, gnunet, 2020/04/22
- [gnunet] 21/31: predate validity time on creation; extent ttl on validation, gnunet, 2020/04/22
- [gnunet] 28/31: purge scrypt; add argon2, gnunet, 2020/04/22