diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2010-12-03 21:57:38 +0300 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2010-12-03 21:57:38 +0300 |
commit | 618e3f4887b61c69915f1c641ea47044695d6e7f (patch) | |
tree | c36d6f2bcbc17c8590ad6b2088a6f909bbb7af98 /src/util.h | |
parent | 426963bff9e01d7d2f48d0e9eb232ccc11b33808 (diff) | |
download | rspamd-618e3f4887b61c69915f1c641ea47044695d6e7f.tar.gz rspamd-618e3f4887b61c69915f1c641ea47044695d6e7f.zip |
* Start new rspamd 0.3.4
* Add ability to manage per-module, per-worker and per-classifier options in XML parser
Diffstat (limited to 'src/util.h')
-rw-r--r-- | src/util.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/util.h b/src/util.h index 36d650877..2ba01d05e 100644 --- a/src/util.h +++ b/src/util.h @@ -12,6 +12,21 @@ struct workq; struct statfile; struct classifier_config; +/** + * Process type: main or worker + */ +enum process_type { + TYPE_UNKNOWN=-1, + TYPE_MAIN, + TYPE_WORKER, + TYPE_CONTROLLER, + TYPE_LMTP, + TYPE_SMTP, + TYPE_FUZZY, + TYPE_GREYLIST, + TYPE_MAX=255 +}; + /* Create socket and bind or connect it to specified address and port */ gint make_tcp_socket (struct in_addr *, u_short, gboolean is_server, gboolean async); /* Create socket and bind or connect it to specified address and port */ @@ -143,4 +158,19 @@ gsize rspamd_strlcpy (gchar *dst, const gchar *src, gsize siz); */ gchar * rspamd_escape_string (gchar *dst, const gchar *src, gsize len); +/* + * Convert process type to its name + * + * @param type numeric type + * @return string representation of type + */ +const gchar * process_to_str (enum process_type type); +/* + * Convert string to process type + * + * @param type numeric type + * @return string representation of type + */ +enum process_type str_to_process (const gchar *str); + #endif |