[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[taler-anastasis] branch master updated: fixed some buggs still error
From: |
gnunet |
Subject: |
[taler-anastasis] branch master updated: fixed some buggs still error |
Date: |
Thu, 07 Nov 2019 17:11:29 +0100 |
This is an automated email from the git hooks/post-receive script.
ds-meister pushed a commit to branch master
in repository anastasis.
The following commit(s) were added to refs/heads/master by this push:
new e1cdaec fixed some buggs still error
e1cdaec is described below
commit e1cdaecc4b2c4b424b226d9be564652a64146e79
Author: Dominik Meister <address@hidden>
AuthorDate: Thu Nov 7 17:11:16 2019 +0100
fixed some buggs still error
---
src/stasis/Makefile.am | 1 +
src/stasis/anastasis_db_plugin.c | 1 -
src/stasis/plugin_anastasis_postgres.c | 3 ++-
src/stasis/test_anastasis_db.c | 22 +++++++++++-----------
4 files changed, 14 insertions(+), 13 deletions(-)
diff --git a/src/stasis/Makefile.am b/src/stasis/Makefile.am
index 79e72d0..9a47403 100644
--- a/src/stasis/Makefile.am
+++ b/src/stasis/Makefile.am
@@ -38,6 +38,7 @@ libanastasis_plugin_db_postgres_la_LDFLAGS = \
$(TALER_PLUGIN_LDFLAGS) \
-lgnunetpq \
-lpq \
+ -ltalerpq \
-lgnunetutil $(XLIB)
check_PROGRAMS = \
diff --git a/src/stasis/anastasis_db_plugin.c b/src/stasis/anastasis_db_plugin.c
index 112526d..6b2c6e0 100644
--- a/src/stasis/anastasis_db_plugin.c
+++ b/src/stasis/anastasis_db_plugin.c
@@ -147,4 +147,3 @@ plugin_fini ()
/* end of anastasis_db_plugin.c */
-
diff --git a/src/stasis/plugin_anastasis_postgres.c
b/src/stasis/plugin_anastasis_postgres.c
index 4867d85..bf6fea6 100644
--- a/src/stasis/plugin_anastasis_postgres.c
+++ b/src/stasis/plugin_anastasis_postgres.c
@@ -470,7 +470,7 @@ postgres_record_payment (void *cls,
struct PostgresClosure *pg = cls;
enum ANASTASIS_DB_QueryStatus qs;
struct GNUNET_TIME_Absolute paid_until;
-
+
check_connection (pg);
if (GNUNET_OK !=
begin_transaction (pg,
@@ -519,6 +519,7 @@ postgres_record_payment (void *cls,
}
paid_until = GNUNET_TIME_absolute_add (paid_until,
lifetime_inc);
+ GNUNET_TIME_round_abs (&paid_until);
if (ANASTASIS_DB_STATUS_SUCCESS_NO_RESULTS == qs)
{
/* user did not yet exist, create */
diff --git a/src/stasis/test_anastasis_db.c b/src/stasis/test_anastasis_db.c
index ac61eb1..4be1da3 100644
--- a/src/stasis/test_anastasis_db.c
+++ b/src/stasis/test_anastasis_db.c
@@ -1,5 +1,5 @@
/*
- This file is part of TALER
+ This file is part of
(C) 2014-2017 INRIA
TALER is free software; you can redistribute it and/or modify it under the
@@ -32,7 +32,7 @@
do { \
if (! (cond)) { break;} \
GNUNET_break (0); \
- goto drop; \
+ goto drop; \
} while (0)
#define RND_BLK(ptr) \
@@ -190,7 +190,7 @@ run (void *cls)
post_counter = 2;
mime_type = "Picture";
TALER_string_to_amount ("EUR:30",&amount);
- uuid = (struct ANASTASIS_uuid) {"550e8400-e29b-11d4-a716-446655440000"};
+ uuid = (struct ANASTASIS_uuid) { "550e8400-e29b-11d4-a716-446655440000"};
struct GNUNET_TIME_Relative rel_time;
rel_time = GNUNET_TIME_UNIT_SECONDS;
@@ -202,14 +202,6 @@ run (void *cls)
rel_time,
&paymentSecretP));
- FAILIF (ANASTASIS_DB_STATUS_SUCCESS_ONE_RESULT !=
- plugin->store_recovery_document (plugin->cls,
- &accountPubP,
- &recovery_data,
- sizeof (&recovery_data),
- &paymentSecretP,
- &version));
-
FAILIF (ANASTASIS_DB_STATUS_SUCCESS_ONE_RESULT !=
plugin->store_truth (plugin->cls,
&uuid,
@@ -220,6 +212,14 @@ run (void *cls)
sizeof (&key_share),
rel_time));
+ FAILIF (ANASTASIS_DB_STATUS_SUCCESS_ONE_RESULT !=
+ plugin->store_recovery_document (plugin->cls,
+ &accountPubP,
+ &recovery_data,
+ sizeof (&recovery_data),
+ &paymentSecretP,
+ &version));
+
FAILIF (ANASTASIS_DB_STATUS_SUCCESS_ONE_RESULT !=
plugin->get_escrow_challenge (plugin->cls,
&uuid,
--
To stop receiving notification emails like this one, please contact
address@hidden.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [taler-anastasis] branch master updated: fixed some buggs still error,
gnunet <=