From 6af303bd3ab37702ad4a6d50b74e95d2a2808e85 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Sun, 6 Jan 2013 20:33:31 +0400 Subject: Add /maps and /getmap commands to webui. Identify maps by id. Initialize secure random numbers using openssl. Add description to maps. --- src/map.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'src/map.h') diff --git a/src/map.h b/src/map.h index 69fe5f87c..5005786dc 100644 --- a/src/map.h +++ b/src/map.h @@ -12,8 +12,8 @@ */ enum fetch_proto { - PROTO_FILE, - PROTO_HTTP, + MAP_PROTO_FILE, + MAP_PROTO_HTTP, }; /** @@ -70,6 +70,9 @@ struct rspamd_map { struct timeval tv; struct event_base *ev_base; void *map_data; + gchar *uri; + gchar *description; + guint32 id; }; /** @@ -79,7 +82,8 @@ gboolean check_map_proto (const gchar *map_line, gint *res, const gchar **pos); /** * Add map from line */ -gboolean add_map (struct config_file *cfg, const gchar *map_line, map_cb_t read_callback, map_fin_cb_t fin_callback, void **user_data); +gboolean add_map (struct config_file *cfg, const gchar *map_line, const gchar *description, + map_cb_t read_callback, map_fin_cb_t fin_callback, void **user_data); /** * Start watching of maps by adding events to libevent event loop -- cgit v1.2.3