|
|
@@ -1784,10 +1784,11 @@ rspamd_milter_process_milter_block (struct rspamd_milter_session *session, |
|
|
|
ucl_object_iter_t *elt_it; |
|
|
|
|
|
|
|
elt_it = ucl_object_iterate_new (cur); |
|
|
|
const char *key_name = ucl_object_key (cur); |
|
|
|
|
|
|
|
while ((cur_elt = ucl_object_iterate_safe (elt_it, true)) != NULL) { |
|
|
|
while ((cur_elt = ucl_object_iterate_safe (elt_it, false)) != NULL) { |
|
|
|
if (ucl_object_type (cur_elt) == UCL_STRING) { |
|
|
|
hname = g_string_new (ucl_object_key (cur)); |
|
|
|
hname = g_string_new (key_name); |
|
|
|
hvalue = g_string_new (ucl_object_tostring (cur_elt)); |
|
|
|
|
|
|
|
rspamd_milter_send_action (session, |
|
|
@@ -1798,7 +1799,7 @@ rspamd_milter_process_milter_block (struct rspamd_milter_session *session, |
|
|
|
} |
|
|
|
else if (ucl_object_type (cur_elt) == UCL_OBJECT) { |
|
|
|
rspamd_milter_extract_single_header (session, |
|
|
|
ucl_object_key (cur), cur_elt); |
|
|
|
key_name, cur_elt); |
|
|
|
} |
|
|
|
else if (ucl_object_type (cur_elt) == UCL_ARRAY) { |
|
|
|
/* Multiple values for the same key */ |
|
|
@@ -1810,7 +1811,7 @@ rspamd_milter_process_milter_block (struct rspamd_milter_session *session, |
|
|
|
while ((array_elt = ucl_object_iterate_safe (array_it, |
|
|
|
true)) != NULL) { |
|
|
|
rspamd_milter_extract_single_header (session, |
|
|
|
ucl_object_key (cur), array_elt); |
|
|
|
key_name, array_elt); |
|
|
|
} |
|
|
|
|
|
|
|
ucl_object_iterate_free (array_it); |