diff options
author | Christian Grothoff <christian@grothoff.org> | 2021-01-06 10:16:58 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2021-01-06 10:16:58 +0100 |
commit | dc570d0c06cea200378d8b1030242081ebc4e356 (patch) | |
tree | fe8e108289df7441bc588cdb57837113a522d8af | |
parent | adb48b61630a2d3ca0c0d67d564870ef39586eea (diff) | |
download | exchange-dc570d0c06cea200378d8b1030242081ebc4e356.tar.gz exchange-dc570d0c06cea200378d8b1030242081ebc4e356.zip |
better error handling on configuration failures
-rw-r--r-- | src/util/crypto_helper_esign.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/util/crypto_helper_esign.c b/src/util/crypto_helper_esign.c index 8b2b8216a..8d2a9dc58 100644 --- a/src/util/crypto_helper_esign.c +++ b/src/util/crypto_helper_esign.c | |||
@@ -62,6 +62,7 @@ struct TALER_CRYPTO_ExchangeSignHelper | |||
62 | * Have we reached the sync'ed state? | 62 | * Have we reached the sync'ed state? |
63 | */ | 63 | */ |
64 | bool synced; | 64 | bool synced; |
65 | |||
65 | }; | 66 | }; |
66 | 67 | ||
67 | 68 | ||
@@ -239,6 +240,15 @@ TALER_CRYPTO_helper_esign_connect ( | |||
239 | return NULL; | 240 | return NULL; |
240 | } | 241 | } |
241 | esh->template = template; | 242 | esh->template = template; |
243 | if (strlen (template) >= sizeof (esh->sa.sun_path)) | ||
244 | { | ||
245 | GNUNET_log_config_invalid (GNUNET_ERROR_TYPE_ERROR, | ||
246 | "PATHS", | ||
247 | "TALER_RUNTIME_DIR", | ||
248 | "path too long"); | ||
249 | TALER_CRYPTO_helper_esign_disconnect (esh); | ||
250 | return NULL; | ||
251 | } | ||
242 | } | 252 | } |
243 | TALER_CRYPTO_helper_esign_poll (esh); | 253 | TALER_CRYPTO_helper_esign_poll (esh); |
244 | return esh; | 254 | return esh; |