aboutsummaryrefslogtreecommitdiff
path: root/src/or/hs_control.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/or/hs_control.c')
-rw-r--r--src/or/hs_control.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/or/hs_control.c b/src/or/hs_control.c
index 1b1fe78575..87b4e3fca8 100644
--- a/src/or/hs_control.c
+++ b/src/or/hs_control.c
@@ -222,7 +222,9 @@ hs_control_hspost_command(const char *body, const char *onion_address,
/* This can't fail because we require the caller to pass us a valid onion
* address that has passed hs_address_is_valid(). */
- hs_parse_address(onion_address, &identity_pk, NULL, NULL);
+ if (BUG(hs_parse_address(onion_address, &identity_pk, NULL, NULL) < 0)) {
+ goto done; // LCOV_EXCL_LINE
+ }
/* Only decode the plaintext part which is what the directory will do to
* validate before caching. */