aboutsummaryrefslogtreecommitdiffstats
path: root/src/client/rspamdclient.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2019-02-19 17:57:13 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2019-02-19 17:57:13 +0000
commit3f00d108df7c99edd5cb45e34d232a80e159caa3 (patch)
tree1095abc2ae37c9020eeb3ea7af2b87cd16f3c1de /src/client/rspamdclient.c
parentb13907192f14c0a5171b225c21ffbcedfec3d501 (diff)
downloadrspamd-3f00d108df7c99edd5cb45e34d232a80e159caa3.tar.gz
rspamd-3f00d108df7c99edd5cb45e34d232a80e159caa3.zip
[Project] Adopt plugins, workers, rspamadm and rspamc for http_context
Diffstat (limited to 'src/client/rspamdclient.c')
-rw-r--r--src/client/rspamdclient.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/client/rspamdclient.c b/src/client/rspamdclient.c
index b1b550024..54cd490e6 100644
--- a/src/client/rspamdclient.c
+++ b/src/client/rspamdclient.c
@@ -241,8 +241,9 @@ rspamd_client_finish_handler (struct rspamd_http_connection *conn,
}
struct rspamd_client_connection *
-rspamd_client_init (struct event_base *ev_base, const gchar *name,
- guint16 port, gdouble timeout, const gchar *key)
+rspamd_client_init (struct rspamd_http_context *http_ctx,
+ struct event_base *ev_base, const gchar *name,
+ guint16 port, gdouble timeout, const gchar *key)
{
struct rspamd_client_connection *conn;
gint fd;
@@ -256,14 +257,12 @@ rspamd_client_init (struct event_base *ev_base, const gchar *name,
conn->ev_base = ev_base;
conn->fd = fd;
conn->req_sent = FALSE;
- conn->keys_cache = rspamd_keypair_cache_new (32);
- conn->http_conn = rspamd_http_connection_new (rspamd_client_body_handler,
+ conn->http_conn = rspamd_http_connection_new (http_ctx,
+ rspamd_client_body_handler,
rspamd_client_error_handler,
rspamd_client_finish_handler,
0,
- RSPAMD_HTTP_CLIENT,
- conn->keys_cache,
- NULL);
+ RSPAMD_HTTP_CLIENT);
conn->server_name = g_string_new (name);
if (port != 0) {