aboutsummaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2024-11-01 05:29:30 +0100
committerChristian Grothoff <christian@grothoff.org>2024-11-05 10:37:37 +0100
commit869ee4b4859c80d1f789a4da77d7b517e462f210 (patch)
tree52fd5400b67dc5d0e05018dacab32ac8cbca4077 /src/util
parent41b32f3fbc12149ad2754bcd896a128a26b614b3 (diff)
working through auditors
Diffstat (limited to 'src/util')
-rw-r--r--src/util/payto.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/util/payto.c b/src/util/payto.c
index 1190d7e23..df65ade3c 100644
--- a/src/util/payto.c
+++ b/src/util/payto.c
@@ -44,6 +44,22 @@ TALER_full_payto_cmp (const struct TALER_FullPayto a,
}
+int
+TALER_normalized_payto_cmp (const struct TALER_NormalizedPayto a,
+ const struct TALER_NormalizedPayto b)
+{
+ if ( (NULL == a.normalized_payto) &&
+ (NULL == b.normalized_payto) )
+ return 0;
+ if (NULL == a.normalized_payto)
+ return -1;
+ if (NULL == b.normalized_payto)
+ return 1;
+ return strcmp (a.normalized_payto,
+ b.normalized_payto);
+}
+
+
void
TALER_full_payto_normalize_and_hash (const struct TALER_FullPayto in,
struct TALER_NormalizedPaytoHashP *out)