aboutsummaryrefslogtreecommitdiff
path: root/src/scalarproduct/scalarproduct_api.c
diff options
context:
space:
mode:
authorChristian Fuchs <christian.fuchs@cfuchs.net>2013-09-16 11:16:39 +0000
committerChristian Fuchs <christian.fuchs@cfuchs.net>2013-09-16 11:16:39 +0000
commita1d37f58a2f5dad49539fb271c5c027907fc34eb (patch)
tree85c016cf718ca68ff4a3de9677af164faa32cc75 /src/scalarproduct/scalarproduct_api.c
parent67f58609c699790962604bc8bab8b724fc07d583 (diff)
downloadgnunet-a1d37f58a2f5dad49539fb271c5c027907fc34eb.tar.gz
gnunet-a1d37f58a2f5dad49539fb271c5c027907fc34eb.zip
excluded test cases for SP for now, while it does not fully work yet
SP service now properly checks for half-finished sessions in the tunnel teardown handler for alice.
Diffstat (limited to 'src/scalarproduct/scalarproduct_api.c')
-rw-r--r--src/scalarproduct/scalarproduct_api.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/scalarproduct/scalarproduct_api.c b/src/scalarproduct/scalarproduct_api.c
index 09c726c88..eed7c315b 100644
--- a/src/scalarproduct/scalarproduct_api.c
+++ b/src/scalarproduct/scalarproduct_api.c
@@ -190,7 +190,7 @@ process_result_message (void *cls,
190 gcry_mpi_t num; 190 gcry_mpi_t num;
191 size_t read = 0; 191 size_t read = 0;
192 192
193 if (0 != (rc = gcry_mpi_scan (&num, GCRYMPI_FMT_STD, &msg[1], product_len, &read))) 193 if (0 != (rc = gcry_mpi_scan (&num, GCRYMPI_FMT_USG, &msg[1], product_len, &read)))
194 { 194 {
195 LOG_GCRY(GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_scan", rc); 195 LOG_GCRY(GNUNET_ERROR_TYPE_ERROR, "gcry_mpi_scan", rc);
196 gcry_mpi_release (result); 196 gcry_mpi_release (result);
@@ -199,9 +199,9 @@ process_result_message (void *cls,
199 } 199 }
200 else 200 else
201 { 201 {
202 if (message->range > 0) 202 if (0 < message->range)
203 gcry_mpi_add (result, result, num); 203 gcry_mpi_add (result, result, num);
204 else 204 else if (0 > message->range)
205 gcry_mpi_sub (result, result, num); 205 gcry_mpi_sub (result, result, num);
206 gcry_mpi_release (num); 206 gcry_mpi_release (num);
207 } 207 }