fixed the metadata fromdomain value

This commit is contained in:
SJ 2012-11-28 22:15:11 +01:00
parent f219fb4edf
commit e57098ac1b

View File

@ -371,14 +371,10 @@ int store_meta_data(struct session_data *sdata, struct _state *state, struct __d
bind[0].is_null = 0; bind[0].is_null = 0;
len[0] = strlen(s2); bind[0].length = &len[0]; len[0] = strlen(s2); bind[0].length = &len[0];
p = strchr(state->b_from, '@'); bind[1].buffer_type = MYSQL_TYPE_STRING;
if(p && strlen(p) > 3){ bind[1].buffer = state->b_from_domain;
p++; bind[1].is_null = 0;
bind[1].buffer_type = MYSQL_TYPE_STRING; len[1] = strlen(state->b_from_domain); bind[1].length = &len[1];
bind[1].buffer = p;
bind[1].is_null = 0;
len[1] = strlen(p); bind[1].length = &len[1];
}
bind[2].buffer_type = MYSQL_TYPE_STRING; bind[2].buffer_type = MYSQL_TYPE_STRING;
bind[2].buffer = subj; bind[2].buffer = subj;