summaryrefslogtreecommitdiffstats
path: root/ssl/tls_srp.c
diff options
context:
space:
mode:
Diffstat (limited to 'ssl/tls_srp.c')
-rw-r--r--ssl/tls_srp.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/ssl/tls_srp.c b/ssl/tls_srp.c
index 5d895ccab3..5445f3cbe3 100644
--- a/ssl/tls_srp.c
+++ b/ssl/tls_srp.c
@@ -273,14 +273,10 @@ int SSL_set_srp_server_param_pw(SSL *s, const char *user, const char *pass,
return -1;
s->srp_ctx.N = BN_dup(GN->N);
s->srp_ctx.g = BN_dup(GN->g);
- if (s->srp_ctx.v != NULL) {
- BN_clear_free(s->srp_ctx.v);
- s->srp_ctx.v = NULL;
- }
- if (s->srp_ctx.s != NULL) {
- BN_clear_free(s->srp_ctx.s);
- s->srp_ctx.s = NULL;
- }
+ BN_clear_free(s->srp_ctx.v);
+ s->srp_ctx.v = NULL;
+ BN_clear_free(s->srp_ctx.s);
+ s->srp_ctx.s = NULL;
if (!SRP_create_verifier_BN
(user, pass, &s->srp_ctx.s, &s->srp_ctx.v, GN->N, GN->g))
return -1;