aboutsummaryrefslogtreecommitdiff
path: root/src/bank-lib/fakebank.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2021-09-06 01:26:46 +0200
committerChristian Grothoff <christian@grothoff.org>2021-09-06 01:26:46 +0200
commit9086ed15c11db106179d54d125cbd3850eda0dc7 (patch)
tree725d766573306e6bba15c3138b2142baef8beea1 /src/bank-lib/fakebank.c
parent87f5d8211e5c086bf33a0e974fc131a94625af00 (diff)
-misc bugfixes
Diffstat (limited to 'src/bank-lib/fakebank.c')
-rw-r--r--src/bank-lib/fakebank.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/bank-lib/fakebank.c b/src/bank-lib/fakebank.c
index 6a6278ed5..2a53419b6 100644
--- a/src/bank-lib/fakebank.c
+++ b/src/bank-lib/fakebank.c
@@ -597,14 +597,9 @@ lookup_account (struct TALER_FAKEBANK_Handle *h,
0,
sizeof (hc));
slen = strlen (name);
- if (slen < sizeof (hc))
- memcpy (&hc,
- name,
- slen); /* fake hashing for speed! */
- else
- GNUNET_CRYPTO_hash (name,
- strlen (name),
- &hc);
+ GNUNET_CRYPTO_hash (name,
+ slen,
+ &hc);
GNUNET_assert (0 ==
pthread_mutex_lock (&h->accounts_lock));
account = GNUNET_CONTAINER_multihashmap_get (h->accounts,
@@ -2582,6 +2577,8 @@ TALER_FAKEBANK_start2 (uint16_t port,
&handle_mhd_completion_callback, h,
MHD_OPTION_LISTEN_BACKLOG_SIZE,
(unsigned int) 1024,
+ MHD_OPTION_CONNECTION_LIMIT,
+ (unsigned int) 65536,
MHD_OPTION_END);
if (NULL == h->mhd_bank)
{
@@ -2632,6 +2629,8 @@ TALER_FAKEBANK_start2 (uint16_t port,
&handle_mhd_completion_callback, h,
MHD_OPTION_LISTEN_BACKLOG_SIZE,
(unsigned int) 1024,
+ MHD_OPTION_CONNECTION_LIMIT,
+ (unsigned int) 65536,
MHD_OPTION_THREAD_POOL_SIZE,
num_threads,
MHD_OPTION_END);