type = g_quark_try_string ("rspamd_proxy");
- ctx = rspamd_mempool_alloc (cfg->cfg_pool,
+ ctx = rspamd_mempool_alloc0 (cfg->cfg_pool,
sizeof (struct rspamd_proxy_ctx));
ctx->magic = rspamd_rspamd_proxy_magic;
ctx->timeout = 10.0;
"timeout",
rspamd_rcl_parse_struct_time,
ctx,
- G_STRUCT_OFFSET (struct rspamd_proxy_ctx,
- timeout),
+ G_STRUCT_OFFSET (struct rspamd_proxy_ctx, timeout),
RSPAMD_CL_FLAG_TIME_FLOAT,
"IO timeout");
rspamd_rcl_register_worker_option (cfg,
"rotate",
rspamd_rcl_parse_struct_time,
ctx,
- G_STRUCT_OFFSET (struct rspamd_proxy_ctx,
- rotate_tm),
+ G_STRUCT_OFFSET (struct rspamd_proxy_ctx, rotate_tm),
RSPAMD_CL_FLAG_TIME_FLOAT,
"Rotation keys time, default: "
G_STRINGIFY (DEFAULT_ROTATION_TIME) " seconds");
"keypair",
rspamd_rcl_parse_struct_keypair,
ctx,
- G_STRUCT_OFFSET (struct rspamd_proxy_ctx,
- key),
+ G_STRUCT_OFFSET (struct rspamd_proxy_ctx, key),
0,
"Server's keypair");
rspamd_rcl_register_worker_option (cfg,