diff options
author | Christian Grothoff <christian@grothoff.org> | 2014-12-07 00:21:18 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2014-12-07 00:21:18 +0000 |
commit | 7b993324a717497da6d34573a45150c48ca8786f (patch) | |
tree | 0d6416c02b77aaffb8c626c8d10e985739b04774 /src | |
parent | 9bc4b1572a3987199554a824b19b451015f63a78 (diff) | |
download | gnunet-7b993324a717497da6d34573a45150c48ca8786f.tar.gz gnunet-7b993324a717497da6d34573a45150c48ca8786f.zip |
-check return value
Diffstat (limited to 'src')
-rw-r--r-- | src/secretsharing/gnunet-service-secretsharing.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/secretsharing/gnunet-service-secretsharing.c b/src/secretsharing/gnunet-service-secretsharing.c index 3a0461008..0a22561cd 100644 --- a/src/secretsharing/gnunet-service-secretsharing.c +++ b/src/secretsharing/gnunet-service-secretsharing.c | |||
@@ -1645,7 +1645,10 @@ insert_round1_element (struct KeygenSession *ks) | |||
1645 | 1645 | ||
1646 | d->purpose.size = htonl ((sizeof *d) - offsetof (struct GNUNET_SECRETSHARING_KeygenCommitData, purpose)); | 1646 | d->purpose.size = htonl ((sizeof *d) - offsetof (struct GNUNET_SECRETSHARING_KeygenCommitData, purpose)); |
1647 | d->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_SECRETSHARING_DKG1); | 1647 | d->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_SECRETSHARING_DKG1); |
1648 | GNUNET_assert (GNUNET_OK == GNUNET_CRYPTO_eddsa_sign (my_peer_private_key, &d->purpose, &d->signature)); | 1648 | GNUNET_assert (GNUNET_OK == |
1649 | GNUNET_CRYPTO_eddsa_sign (my_peer_private_key, | ||
1650 | &d->purpose, | ||
1651 | &d->signature)); | ||
1649 | 1652 | ||
1650 | GNUNET_CONSENSUS_insert (ks->consensus, element, NULL, NULL); | 1653 | GNUNET_CONSENSUS_insert (ks->consensus, element, NULL, NULL); |
1651 | 1654 | ||
@@ -2066,10 +2069,14 @@ insert_decrypt_element (struct DecryptSession *ds) | |||
2066 | d.purpose.size = htonl (element.size - offsetof (struct GNUNET_SECRETSHARING_DecryptData, purpose)); | 2069 | d.purpose.size = htonl (element.size - offsetof (struct GNUNET_SECRETSHARING_DecryptData, purpose)); |
2067 | d.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_SECRETSHARING_DECRYPTION); | 2070 | d.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_SECRETSHARING_DECRYPTION); |
2068 | 2071 | ||
2069 | GNUNET_CRYPTO_eddsa_sign (my_peer_private_key, &d.purpose, &d.signature); | 2072 | GNUNET_assert (GNUNET_OK == |
2073 | GNUNET_CRYPTO_eddsa_sign (my_peer_private_key, | ||
2074 | &d.purpose, | ||
2075 | &d.signature)); | ||
2070 | 2076 | ||
2071 | GNUNET_CONSENSUS_insert (ds->consensus, &element, NULL, NULL); | 2077 | GNUNET_CONSENSUS_insert (ds->consensus, &element, NULL, NULL); |
2072 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "P%u: Inserting decrypt element done!\n", | 2078 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2079 | "P%u: Inserting decrypt element done!\n", | ||
2073 | ds->share->my_peer); | 2080 | ds->share->my_peer); |
2074 | 2081 | ||
2075 | gcry_mpi_release (s); | 2082 | gcry_mpi_release (s); |