-check return value
authorChristian Grothoff <christian@grothoff.org>
Sun, 7 Dec 2014 00:21:18 +0000 (00:21 +0000)
committerChristian Grothoff <christian@grothoff.org>
Sun, 7 Dec 2014 00:21:18 +0000 (00:21 +0000)
src/secretsharing/gnunet-service-secretsharing.c

index 3a0461008bc07fb9efdf51e1be55038da7077124..0a22561cda5d3903dbea85028d4e208a2775af39 100644 (file)
@@ -1645,7 +1645,10 @@ insert_round1_element (struct KeygenSession *ks)
 
   d->purpose.size = htonl ((sizeof *d) - offsetof (struct GNUNET_SECRETSHARING_KeygenCommitData, purpose));
   d->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_SECRETSHARING_DKG1);
-  GNUNET_assert (GNUNET_OK == GNUNET_CRYPTO_eddsa_sign (my_peer_private_key, &d->purpose, &d->signature));
+  GNUNET_assert (GNUNET_OK ==
+                 GNUNET_CRYPTO_eddsa_sign (my_peer_private_key,
+                                           &d->purpose,
+                                           &d->signature));
 
   GNUNET_CONSENSUS_insert (ks->consensus, element, NULL, NULL);
 
@@ -2066,10 +2069,14 @@ insert_decrypt_element (struct DecryptSession *ds)
   d.purpose.size = htonl (element.size - offsetof (struct GNUNET_SECRETSHARING_DecryptData, purpose));
   d.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_SECRETSHARING_DECRYPTION);
 
-  GNUNET_CRYPTO_eddsa_sign (my_peer_private_key, &d.purpose, &d.signature);
+  GNUNET_assert (GNUNET_OK ==
+                 GNUNET_CRYPTO_eddsa_sign (my_peer_private_key,
+                                           &d.purpose,
+                                           &d.signature));
 
   GNUNET_CONSENSUS_insert (ds->consensus, &element, NULL, NULL);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "P%u: Inserting decrypt element done!\n",
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+              "P%u: Inserting decrypt element done!\n",
               ds->share->my_peer);
 
   gcry_mpi_release (s);