mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-12-25 19:30:12 +01:00
fixing an odd exchange behaviour
This commit is contained in:
parent
c4928d1710
commit
dd2ea801bf
@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
#define VERSION "0.1.25-master-branch"
|
#define VERSION "0.1.25-master-branch"
|
||||||
|
|
||||||
#define BUILD 856
|
#define BUILD 857
|
||||||
|
|
||||||
#define HOSTID "mailarchiver"
|
#define HOSTID "mailarchiver"
|
||||||
|
|
||||||
|
@ -199,6 +199,7 @@ struct session_data {
|
|||||||
char digest[2*DIGEST_LENGTH+1];
|
char digest[2*DIGEST_LENGTH+1];
|
||||||
time_t now, sent, delivered, retained;
|
time_t now, sent, delivered, retained;
|
||||||
char ms_journal;
|
char ms_journal;
|
||||||
|
char import;
|
||||||
int journal_envelope_length, journal_bottom_length;
|
int journal_envelope_length, journal_bottom_length;
|
||||||
#ifdef NEED_MYSQL
|
#ifdef NEED_MYSQL
|
||||||
MYSQL mysql;
|
MYSQL mysql;
|
||||||
|
@ -69,6 +69,8 @@ int import_message(char *filename, struct session_data *sdata, struct __data *da
|
|||||||
sdata->sent = 0;
|
sdata->sent = 0;
|
||||||
sdata->delivered = 0;
|
sdata->delivered = 0;
|
||||||
|
|
||||||
|
sdata->import = 1;
|
||||||
|
|
||||||
state = parse_message(sdata, 1, data, cfg);
|
state = parse_message(sdata, 1, data, cfg);
|
||||||
post_parse(sdata, &state, cfg);
|
post_parse(sdata, &state, cfg);
|
||||||
|
|
||||||
|
@ -471,6 +471,7 @@ void init_session_data(struct session_data *sdata, struct __config *cfg){
|
|||||||
|
|
||||||
sdata->__acquire = sdata->__parsed = sdata->__av = sdata->__store = sdata->__compress = sdata->__encrypt = 0;
|
sdata->__acquire = sdata->__parsed = sdata->__av = sdata->__store = sdata->__compress = sdata->__encrypt = 0;
|
||||||
|
|
||||||
|
sdata->import = 0;
|
||||||
|
|
||||||
for(i=0; i<MAX_RCPT_TO; i++) memset(sdata->rcptto[i], 0, SMALLBUFSIZE);
|
for(i=0; i<MAX_RCPT_TO; i++) memset(sdata->rcptto[i], 0, SMALLBUFSIZE);
|
||||||
|
|
||||||
|
@ -186,7 +186,7 @@ int parse_line(char *buf, struct _state *state, struct session_data *sdata, int
|
|||||||
sdata->spam_message = 1;
|
sdata->spam_message = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(state->is_1st_header == 1 && sdata->ms_journal == 0 && (strncmp(buf, "X-MS-Journal-Report:", strlen("X-MS-Journal-Report:")) == 0 || strncmp(buf, "X-MS-Exchange-Organization-Auth", strlen("X-MS-Exchange-Organization-Auth")) == 0)){
|
if(state->is_1st_header == 1 && sdata->ms_journal == 0 && (strncmp(buf, "X-MS-Journal-Report:", strlen("X-MS-Journal-Report:")) == 0 || (sdata->import == 1 && strncmp(buf, "X-MS-Exchange-Organization-Auth", strlen("X-MS-Exchange-Organization-Auth")) == 0))){
|
||||||
sdata->ms_journal = 1;
|
sdata->ms_journal = 1;
|
||||||
memset(state->message_id, 0, SMALLBUFSIZE);
|
memset(state->message_id, 0, SMALLBUFSIZE);
|
||||||
|
|
||||||
|
@ -318,6 +318,7 @@ void initialise_configuration(){
|
|||||||
|
|
||||||
data.folder = 0;
|
data.folder = 0;
|
||||||
data.recursive_folder_names = 0;
|
data.recursive_folder_names = 0;
|
||||||
|
|
||||||
inithash(data.mydomains);
|
inithash(data.mydomains);
|
||||||
initrules(data.archiving_rules);
|
initrules(data.archiving_rules);
|
||||||
initrules(data.retention_rules);
|
initrules(data.retention_rules);
|
||||||
|
@ -217,6 +217,7 @@ int main(int argc, char **argv){
|
|||||||
|
|
||||||
data.folder = 0;
|
data.folder = 0;
|
||||||
data.recursive_folder_names = 0;
|
data.recursive_folder_names = 0;
|
||||||
|
|
||||||
inithash(data.mydomains);
|
inithash(data.mydomains);
|
||||||
initrules(data.archiving_rules);
|
initrules(data.archiving_rules);
|
||||||
initrules(data.retention_rules);
|
initrules(data.retention_rules);
|
||||||
|
Loading…
Reference in New Issue
Block a user