mirror of
https://bitbucket.org/jsuto/piler.git
synced 2025-06-12 23:17:02 +02:00
added an option to decide whether to add rcpt to addresses to rcpt table
This commit is contained in:
@ -99,6 +99,7 @@ struct _parse_rule config_parse_rules[] =
|
||||
{ "pilergetd_listen_port", "integer", (void*) int_parser, offsetof(struct __config, pilergetd_listen_port), "10091", sizeof(int)},
|
||||
{ "pilergetd_password", "string", (void*) string_parser, offsetof(struct __config, pilergetd_password), "xxxxxxxxxx", MAXVAL-1},
|
||||
{ "pilergetd_pidfile", "string", (void*) string_parser, offsetof(struct __config, pilergetd_pidfile), PILERGETD_PIDFILE, MAXVAL-1},
|
||||
{ "process_rcpt_to_addresses", "integer", (void*) int_parser, offsetof(struct __config, process_rcpt_to_addresses), "0", sizeof(int)},
|
||||
{ "queuedir", "string", (void*) string_parser, offsetof(struct __config, queuedir), QUEUE_DIR, MAXVAL-1},
|
||||
{ "server_id", "integer", (void*) int_parser, offsetof(struct __config, server_id), "0", sizeof(int)},
|
||||
{ "spam_header_line", "string", (void*) string_parser, offsetof(struct __config, spam_header_line), "", MAXVAL-1},
|
||||
|
@ -45,6 +45,8 @@ struct __config {
|
||||
|
||||
int backlog;
|
||||
|
||||
int process_rcpt_to_addresses;
|
||||
|
||||
char workdir[MAXVAL];
|
||||
char queuedir[MAXVAL];
|
||||
|
||||
|
@ -32,7 +32,7 @@ struct _state parse_message(struct session_data *sdata, int take_into_pieces, st
|
||||
}
|
||||
|
||||
|
||||
if(sdata->num_of_rcpt_to > 0){
|
||||
if(sdata->num_of_rcpt_to > 0 && cfg->process_rcpt_to_addresses == 1){
|
||||
for(i=0; i<sdata->num_of_rcpt_to; i++){
|
||||
|
||||
snprintf(puf, sizeof(puf)-1, "%s ", sdata->rcptto[i]);
|
||||
|
Reference in New Issue
Block a user