diff options
author | Christian Grothoff <christian@grothoff.org> | 2022-06-05 23:48:41 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2022-06-05 23:48:41 +0200 |
commit | bf16c6e29031e828c946a23002c323aa6f0d78de (patch) | |
tree | ca93c7de7f6fa8b6ce4a4d386d1d08fcec1782e4 /src | |
parent | 41eb57c7252bd14794502a7164acb5794df1a3ae (diff) | |
download | merchant-bf16c6e29031e828c946a23002c323aa6f0d78de.tar.gz merchant-bf16c6e29031e828c946a23002c323aa6f0d78de.tar.bz2 merchant-bf16c6e29031e828c946a23002c323aa6f0d78de.zip |
-fix backenddb crash
Diffstat (limited to 'src')
-rw-r--r-- | src/backenddb/drop0001.sql | 5 | ||||
-rw-r--r-- | src/backenddb/drop0002.sql | 31 | ||||
-rw-r--r-- | src/backenddb/test_merchantdb.c | 3 |
3 files changed, 4 insertions, 35 deletions
diff --git a/src/backenddb/drop0001.sql b/src/backenddb/drop0001.sql index cc24f059..ceff6af5 100644 --- a/src/backenddb/drop0001.sql +++ b/src/backenddb/drop0001.sql @@ -26,10 +26,7 @@ BEGIN; -- Unregister patch (0003.sql) --SELECT _v.unregister_patch('merchant-0003'); --- Unregister patch (0002.sql) ---SELECT _v.unregister_patch('merchant-0002'); - --- Unregister patch (0001.sql) +SELECT _v.unregister_patch('merchant-0002'); SELECT _v.unregister_patch('merchant-0001'); diff --git a/src/backenddb/drop0002.sql b/src/backenddb/drop0002.sql deleted file mode 100644 index cfb6773c..00000000 --- a/src/backenddb/drop0002.sql +++ /dev/null @@ -1,31 +0,0 @@ --- --- This file is part of TALER --- Copyright (C) 2014--2021 Taler Systems SA --- --- TALER is free software; you can redistribute it and/or modify it under the --- terms of the GNU General Public License as published by the Free Software --- Foundation; either version 3, or (at your option) any later version. --- --- TALER is distributed in the hope that it will be useful, but WITHOUT ANY --- WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR --- A PARTICULAR PURPOSE. See the GNU General Public License for more details. --- --- You should have received a copy of the GNU General Public License along with --- TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/> --- - --- Everything in one big transaction -BEGIN; - -SELECT _v.unregister_patch('merchant-0002'); - - --- Drops for 0002.sql -ALTER TABLE merchant_instances - DROP COLUMN website, - DROP COLUMN email, - DROP COLUMN logo; - - --- And we're out of here... -COMMIT; diff --git a/src/backenddb/test_merchantdb.c b/src/backenddb/test_merchantdb.c index f7c2dde7..2d764e7d 100644 --- a/src/backenddb/test_merchantdb.c +++ b/src/backenddb/test_merchantdb.c @@ -100,6 +100,9 @@ static void make_instance (char *instance_id, struct InstanceData *instance) { + memset (instance, + 0, + sizeof (*instance)); GNUNET_CRYPTO_eddsa_key_create (&instance->merchant_priv.eddsa_priv); GNUNET_CRYPTO_eddsa_key_get_public (&instance->merchant_priv.eddsa_priv, &instance->merchant_pub.eddsa_pub); |