aboutsummaryrefslogtreecommitdiffstats
path: root/src/libutil
diff options
context:
space:
mode:
Diffstat (limited to 'src/libutil')
-rw-r--r--src/libutil/http.c3
-rw-r--r--src/libutil/regexp.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/src/libutil/http.c b/src/libutil/http.c
index 21b763108..a5dcf6f03 100644
--- a/src/libutil/http.c
+++ b/src/libutil/http.c
@@ -431,6 +431,9 @@ rspamd_http_parse_key (rspamd_ftok_t *data, struct rspamd_http_connection *conn,
priv->local_key, priv->msg->peer_key);
}
}
+ else {
+ rspamd_pubkey_unref (pk);
+ }
}
}
diff --git a/src/libutil/regexp.c b/src/libutil/regexp.c
index 023cc325d..4cc012567 100644
--- a/src/libutil/regexp.c
+++ b/src/libutil/regexp.c
@@ -476,7 +476,7 @@ fin:
res->raw_re = pcre2_compile (real_pattern, PCRE2_ZERO_TERMINATED,
regexp_flags & ~PCRE_FLAG(UTF),
&err_code, &err_off, pcre2_ctx);
- if (r == NULL) {
+ if (res->raw_re == NULL) {
err_str = g_alloca (1024);
memset (err_str, 0, 1024);
pcre2_get_error_message (err_code, err_str, 1024);