Further cleanup of sieve namespace
Prefix internal function names with mu_i_
Showing
10 changed files
with
60 additions
and
54 deletions
... | @@ -563,7 +563,7 @@ static mu_sieve_tag_group_t fileinto_tag_groups[] = { | ... | @@ -563,7 +563,7 @@ static mu_sieve_tag_group_t fileinto_tag_groups[] = { |
563 | }; | 563 | }; |
564 | 564 | ||
565 | void | 565 | void |
566 | mu_sv_register_standard_actions (mu_sieve_machine_t mach) | 566 | mu_i_sv_register_standard_actions (mu_sieve_machine_t mach) |
567 | { | 567 | { |
568 | mu_sieve_register_action (mach, "stop", sieve_action_stop, NULL, NULL, 1); | 568 | mu_sieve_register_action (mach, "stop", sieve_action_stop, NULL, NULL, 1); |
569 | mu_sieve_register_action (mach, "keep", sieve_action_keep, NULL, NULL, 1); | 569 | mu_sieve_register_action (mach, "keep", sieve_action_keep, NULL, NULL, 1); | ... | ... |
... | @@ -502,7 +502,7 @@ i_ascii_numeric_eq (const char *pattern, const char *text) | ... | @@ -502,7 +502,7 @@ i_ascii_numeric_eq (const char *pattern, const char *text) |
502 | } | 502 | } |
503 | 503 | ||
504 | void | 504 | void |
505 | mu_sv_register_standard_comparators (mu_sieve_machine_t mach) | 505 | mu_i_sv_register_standard_comparators (mu_sieve_machine_t mach) |
506 | { | 506 | { |
507 | mu_sieve_register_comparator (mach, | 507 | mu_sieve_register_comparator (mach, |
508 | "i;octet", | 508 | "i;octet", | ... | ... |
... | @@ -136,7 +136,7 @@ _add_load_dir (void *item, void *unused) | ... | @@ -136,7 +136,7 @@ _add_load_dir (void *item, void *unused) |
136 | } | 136 | } |
137 | 137 | ||
138 | int | 138 | int |
139 | mu_sv_load_add_dir (mu_sieve_machine_t mach, const char *name) | 139 | mu_i_sv_load_add_dir (mu_sieve_machine_t mach, const char *name) |
140 | { | 140 | { |
141 | if (sieve_init_load_path ()) | 141 | if (sieve_init_load_path ()) |
142 | return 1; | 142 | return 1; |
... | @@ -155,7 +155,7 @@ mu_sieve_load_ext (mu_sieve_machine_t mach, const char *name) | ... | @@ -155,7 +155,7 @@ mu_sieve_load_ext (mu_sieve_machine_t mach, const char *name) |
155 | } | 155 | } |
156 | 156 | ||
157 | int | 157 | int |
158 | mu_sv_load_add_dir (mu_sieve_machine_t mach, const char *name) | 158 | mu_i_sv_load_add_dir (mu_sieve_machine_t mach, const char *name) |
159 | { | 159 | { |
160 | return 1; | 160 | return 1; |
161 | } | 161 | } | ... | ... |
... | @@ -50,7 +50,7 @@ file_eq (char const *a, char const *b) | ... | @@ -50,7 +50,7 @@ file_eq (char const *a, char const *b) |
50 | { | 50 | { |
51 | if (a) | 51 | if (a) |
52 | return b ? (strcmp (a, b) == 0) : 1; | 52 | return b ? (strcmp (a, b) == 0) : 1; |
53 | return b ? -1 : 0; | 53 | return b ? 0 : 1; |
54 | } | 54 | } |
55 | 55 | ||
56 | /* FIXME: 1. Only beg is stored | 56 | /* FIXME: 1. Only beg is stored |
... | @@ -61,12 +61,12 @@ mu_i_sv_locus (struct mu_sieve_machine *mach, struct mu_locus_range *lr) | ... | @@ -61,12 +61,12 @@ mu_i_sv_locus (struct mu_sieve_machine *mach, struct mu_locus_range *lr) |
61 | { | 61 | { |
62 | if (!file_eq (mach->locus.mu_file, lr->beg.mu_file)) | 62 | if (!file_eq (mach->locus.mu_file, lr->beg.mu_file)) |
63 | { | 63 | { |
64 | mu_i_sv_code (mach, (sieve_op_t) _mu_sv_instr_source); | 64 | mu_i_sv_code (mach, (sieve_op_t) _mu_i_sv_instr_source); |
65 | mu_i_sv_code (mach, (sieve_op_t) lr->beg.mu_file); | 65 | mu_i_sv_code (mach, (sieve_op_t) lr->beg.mu_file); |
66 | } | 66 | } |
67 | if (mach->locus.mu_line != lr->beg.mu_line) | 67 | if (mach->locus.mu_line != lr->beg.mu_line) |
68 | { | 68 | { |
69 | mu_i_sv_code (mach, (sieve_op_t) _mu_sv_instr_line); | 69 | mu_i_sv_code (mach, (sieve_op_t) _mu_i_sv_instr_line); |
70 | mu_i_sv_code (mach, (sieve_op_t) lr->beg.mu_line); | 70 | mu_i_sv_code (mach, (sieve_op_t) lr->beg.mu_line); |
71 | } | 71 | } |
72 | 72 | ||
... | @@ -339,7 +339,7 @@ int | ... | @@ -339,7 +339,7 @@ int |
339 | mu_i_sv_code_action (struct mu_sieve_machine *mach, | 339 | mu_i_sv_code_action (struct mu_sieve_machine *mach, |
340 | mu_sieve_register_t *reg, mu_list_t arglist) | 340 | mu_sieve_register_t *reg, mu_list_t arglist) |
341 | { | 341 | { |
342 | return mu_i_sv_code (mach, (sieve_op_t) _mu_sv_instr_action) | 342 | return mu_i_sv_code (mach, (sieve_op_t) _mu_i_sv_instr_action) |
343 | || sv_code_command (mach, reg, arglist); | 343 | || sv_code_command (mach, reg, arglist); |
344 | } | 344 | } |
345 | 345 | ||
... | @@ -347,7 +347,7 @@ int | ... | @@ -347,7 +347,7 @@ int |
347 | mu_i_sv_code_test (struct mu_sieve_machine *mach, | 347 | mu_i_sv_code_test (struct mu_sieve_machine *mach, |
348 | mu_sieve_register_t *reg, mu_list_t arglist) | 348 | mu_sieve_register_t *reg, mu_list_t arglist) |
349 | { | 349 | { |
350 | return mu_i_sv_code (mach, (sieve_op_t) _mu_sv_instr_test) | 350 | return mu_i_sv_code (mach, (sieve_op_t) _mu_i_sv_instr_test) |
351 | || sv_code_command (mach, reg, arglist); | 351 | || sv_code_command (mach, reg, arglist); |
352 | } | 352 | } |
353 | 353 | ... | ... |
... | @@ -32,14 +32,14 @@ | ... | @@ -32,14 +32,14 @@ |
32 | #define INSTR_DISASS(m) ((m)->debug_level & MU_SIEVE_DEBUG_DISAS) | 32 | #define INSTR_DISASS(m) ((m)->debug_level & MU_SIEVE_DEBUG_DISAS) |
33 | 33 | ||
34 | void | 34 | void |
35 | _mu_sv_instr_nop (mu_sieve_machine_t mach) | 35 | _mu_i_sv_instr_nop (mu_sieve_machine_t mach) |
36 | { | 36 | { |
37 | if (INSTR_DEBUG (mach)) | 37 | if (INSTR_DEBUG (mach)) |
38 | mu_sieve_debug (mach, "%4lu: NOP", (unsigned long) (mach->pc - 1)); | 38 | mu_sieve_debug (mach, "%4lu: NOP", (unsigned long) (mach->pc - 1)); |
39 | } | 39 | } |
40 | 40 | ||
41 | void | 41 | void |
42 | _mu_sv_instr_source (mu_sieve_machine_t mach) | 42 | _mu_i_sv_instr_source (mu_sieve_machine_t mach) |
43 | { | 43 | { |
44 | mach->locus.mu_file = (char*) SIEVE_ARG (mach, 0, string); | 44 | mach->locus.mu_file = (char*) SIEVE_ARG (mach, 0, string); |
45 | mu_stream_ioctl (mach->errstream, MU_IOCTL_LOGSTREAM, | 45 | mu_stream_ioctl (mach->errstream, MU_IOCTL_LOGSTREAM, |
... | @@ -53,7 +53,7 @@ _mu_sv_instr_source (mu_sieve_machine_t mach) | ... | @@ -53,7 +53,7 @@ _mu_sv_instr_source (mu_sieve_machine_t mach) |
53 | } | 53 | } |
54 | 54 | ||
55 | void | 55 | void |
56 | _mu_sv_instr_line (mu_sieve_machine_t mach) | 56 | _mu_i_sv_instr_line (mu_sieve_machine_t mach) |
57 | { | 57 | { |
58 | mach->locus.mu_line = SIEVE_ARG (mach, 0, line); | 58 | mach->locus.mu_line = SIEVE_ARG (mach, 0, line); |
59 | mu_stream_ioctl (mach->errstream, MU_IOCTL_LOGSTREAM, | 59 | mu_stream_ioctl (mach->errstream, MU_IOCTL_LOGSTREAM, |
... | @@ -80,9 +80,9 @@ instr_run (mu_sieve_machine_t mach) | ... | @@ -80,9 +80,9 @@ instr_run (mu_sieve_machine_t mach) |
80 | { | 80 | { |
81 | mu_stream_printf (mach->errstream, | 81 | mu_stream_printf (mach->errstream, |
82 | "\033s<%d>Arguments: ", MU_LOG_DEBUG); | 82 | "\033s<%d>Arguments: ", MU_LOG_DEBUG); |
83 | mu_sv_print_value_list (arg_list, mach->errstream); | 83 | mu_i_sv_print_value_list (arg_list, mach->errstream); |
84 | mu_stream_printf (mach->errstream, "\n\033s<%d>Tags: ", MU_LOG_DEBUG); | 84 | mu_stream_printf (mach->errstream, "\n\033s<%d>Tags: ", MU_LOG_DEBUG); |
85 | mu_sv_print_tag_list (tag_list, mach->errstream); | 85 | mu_i_sv_print_tag_list (tag_list, mach->errstream); |
86 | mu_stream_printf (mach->errstream, "\n"); | 86 | mu_stream_printf (mach->errstream, "\n"); |
87 | } | 87 | } |
88 | 88 | ||
... | @@ -92,7 +92,7 @@ instr_run (mu_sieve_machine_t mach) | ... | @@ -92,7 +92,7 @@ instr_run (mu_sieve_machine_t mach) |
92 | } | 92 | } |
93 | 93 | ||
94 | void | 94 | void |
95 | _mu_sv_instr_action (mu_sieve_machine_t mach) | 95 | _mu_i_sv_instr_action (mu_sieve_machine_t mach) |
96 | { | 96 | { |
97 | mach->identifier = SIEVE_ARG (mach, 3, string); | 97 | mach->identifier = SIEVE_ARG (mach, 3, string); |
98 | if (INSTR_DEBUG (mach)) | 98 | if (INSTR_DEBUG (mach)) |
... | @@ -105,7 +105,7 @@ _mu_sv_instr_action (mu_sieve_machine_t mach) | ... | @@ -105,7 +105,7 @@ _mu_sv_instr_action (mu_sieve_machine_t mach) |
105 | } | 105 | } |
106 | 106 | ||
107 | void | 107 | void |
108 | _mu_sv_instr_test (mu_sieve_machine_t mach) | 108 | _mu_i_sv_instr_test (mu_sieve_machine_t mach) |
109 | { | 109 | { |
110 | mach->identifier = SIEVE_ARG (mach, 3, string); | 110 | mach->identifier = SIEVE_ARG (mach, 3, string); |
111 | if (INSTR_DEBUG (mach)) | 111 | if (INSTR_DEBUG (mach)) |
... | @@ -117,7 +117,7 @@ _mu_sv_instr_test (mu_sieve_machine_t mach) | ... | @@ -117,7 +117,7 @@ _mu_sv_instr_test (mu_sieve_machine_t mach) |
117 | } | 117 | } |
118 | 118 | ||
119 | void | 119 | void |
120 | _mu_sv_instr_push (mu_sieve_machine_t mach) | 120 | _mu_i_sv_instr_push (mu_sieve_machine_t mach) |
121 | { | 121 | { |
122 | if (INSTR_DEBUG (mach)) | 122 | if (INSTR_DEBUG (mach)) |
123 | { | 123 | { |
... | @@ -135,7 +135,7 @@ _mu_sv_instr_push (mu_sieve_machine_t mach) | ... | @@ -135,7 +135,7 @@ _mu_sv_instr_push (mu_sieve_machine_t mach) |
135 | } | 135 | } |
136 | 136 | ||
137 | void | 137 | void |
138 | _mu_sv_instr_pop (mu_sieve_machine_t mach) | 138 | _mu_i_sv_instr_pop (mu_sieve_machine_t mach) |
139 | { | 139 | { |
140 | if (INSTR_DEBUG (mach)) | 140 | if (INSTR_DEBUG (mach)) |
141 | { | 141 | { |
... | @@ -153,7 +153,7 @@ _mu_sv_instr_pop (mu_sieve_machine_t mach) | ... | @@ -153,7 +153,7 @@ _mu_sv_instr_pop (mu_sieve_machine_t mach) |
153 | } | 153 | } |
154 | 154 | ||
155 | void | 155 | void |
156 | _mu_sv_instr_not (mu_sieve_machine_t mach) | 156 | _mu_i_sv_instr_not (mu_sieve_machine_t mach) |
157 | { | 157 | { |
158 | if (INSTR_DEBUG (mach)) | 158 | if (INSTR_DEBUG (mach)) |
159 | { | 159 | { |
... | @@ -165,7 +165,7 @@ _mu_sv_instr_not (mu_sieve_machine_t mach) | ... | @@ -165,7 +165,7 @@ _mu_sv_instr_not (mu_sieve_machine_t mach) |
165 | } | 165 | } |
166 | 166 | ||
167 | void | 167 | void |
168 | _mu_sv_instr_branch (mu_sieve_machine_t mach) | 168 | _mu_i_sv_instr_branch (mu_sieve_machine_t mach) |
169 | { | 169 | { |
170 | long num = SIEVE_ARG (mach, 0, number); | 170 | long num = SIEVE_ARG (mach, 0, number); |
171 | 171 | ||
... | @@ -183,7 +183,7 @@ _mu_sv_instr_branch (mu_sieve_machine_t mach) | ... | @@ -183,7 +183,7 @@ _mu_sv_instr_branch (mu_sieve_machine_t mach) |
183 | } | 183 | } |
184 | 184 | ||
185 | void | 185 | void |
186 | _mu_sv_instr_brz (mu_sieve_machine_t mach) | 186 | _mu_i_sv_instr_brz (mu_sieve_machine_t mach) |
187 | { | 187 | { |
188 | long num = SIEVE_ARG (mach, 0, number); | 188 | long num = SIEVE_ARG (mach, 0, number); |
189 | SIEVE_ADJUST (mach, 1); | 189 | SIEVE_ADJUST (mach, 1); |
... | @@ -202,7 +202,7 @@ _mu_sv_instr_brz (mu_sieve_machine_t mach) | ... | @@ -202,7 +202,7 @@ _mu_sv_instr_brz (mu_sieve_machine_t mach) |
202 | } | 202 | } |
203 | 203 | ||
204 | void | 204 | void |
205 | _mu_sv_instr_brnz (mu_sieve_machine_t mach) | 205 | _mu_i_sv_instr_brnz (mu_sieve_machine_t mach) |
206 | { | 206 | { |
207 | long num = SIEVE_ARG (mach, 0, number); | 207 | long num = SIEVE_ARG (mach, 0, number); |
208 | SIEVE_ADJUST (mach, 1); | 208 | SIEVE_ADJUST (mach, 1); | ... | ... |
... | @@ -157,26 +157,26 @@ int mu_i_sv_code_test (struct mu_sieve_machine *mach, | ... | @@ -157,26 +157,26 @@ int mu_i_sv_code_test (struct mu_sieve_machine *mach, |
157 | mu_sieve_register_t *reg, mu_list_t arglist); | 157 | mu_sieve_register_t *reg, mu_list_t arglist); |
158 | 158 | ||
159 | /* Opcodes */ | 159 | /* Opcodes */ |
160 | void _mu_sv_instr_action (mu_sieve_machine_t mach); | 160 | void _mu_i_sv_instr_action (mu_sieve_machine_t mach); |
161 | void _mu_sv_instr_test (mu_sieve_machine_t mach); | 161 | void _mu_i_sv_instr_test (mu_sieve_machine_t mach); |
162 | void _mu_sv_instr_push (mu_sieve_machine_t mach); | 162 | void _mu_i_sv_instr_push (mu_sieve_machine_t mach); |
163 | void _mu_sv_instr_pop (mu_sieve_machine_t mach); | 163 | void _mu_i_sv_instr_pop (mu_sieve_machine_t mach); |
164 | void _mu_sv_instr_not (mu_sieve_machine_t mach); | 164 | void _mu_i_sv_instr_not (mu_sieve_machine_t mach); |
165 | void _mu_sv_instr_branch (mu_sieve_machine_t mach); | 165 | void _mu_i_sv_instr_branch (mu_sieve_machine_t mach); |
166 | void _mu_sv_instr_brz (mu_sieve_machine_t mach); | 166 | void _mu_i_sv_instr_brz (mu_sieve_machine_t mach); |
167 | void _mu_sv_instr_brnz (mu_sieve_machine_t mach); | 167 | void _mu_i_sv_instr_brnz (mu_sieve_machine_t mach); |
168 | void _mu_sv_instr_nop (mu_sieve_machine_t mach); | 168 | void _mu_i_sv_instr_nop (mu_sieve_machine_t mach); |
169 | void _mu_sv_instr_source (mu_sieve_machine_t mach); | 169 | void _mu_i_sv_instr_source (mu_sieve_machine_t mach); |
170 | void _mu_sv_instr_line (mu_sieve_machine_t mach); | 170 | void _mu_i_sv_instr_line (mu_sieve_machine_t mach); |
171 | 171 | ||
172 | int mu_sv_load_add_dir (mu_sieve_machine_t mach, const char *name); | 172 | int mu_i_sv_load_add_dir (mu_sieve_machine_t mach, const char *name); |
173 | 173 | ||
174 | void mu_sv_register_standard_actions (mu_sieve_machine_t mach); | 174 | void mu_i_sv_register_standard_actions (mu_sieve_machine_t mach); |
175 | void mu_sv_register_standard_tests (mu_sieve_machine_t mach); | 175 | void mu_i_sv_register_standard_tests (mu_sieve_machine_t mach); |
176 | void mu_sv_register_standard_comparators (mu_sieve_machine_t mach); | 176 | void mu_i_sv_register_standard_comparators (mu_sieve_machine_t mach); |
177 | 177 | ||
178 | void mu_sv_print_value_list (mu_list_t list, mu_stream_t str); | 178 | void mu_i_sv_print_value_list (mu_list_t list, mu_stream_t str); |
179 | void mu_sv_print_tag_list (mu_list_t list, mu_stream_t str); | 179 | void mu_i_sv_print_tag_list (mu_list_t list, mu_stream_t str); |
180 | 180 | ||
181 | void mu_i_sv_error (mu_sieve_machine_t mach); | 181 | void mu_i_sv_error (mu_sieve_machine_t mach); |
182 | 182 | ... | ... |
... | @@ -461,7 +461,7 @@ sieve_searchpath (void) | ... | @@ -461,7 +461,7 @@ sieve_searchpath (void) |
461 | name = get_file_name (p, endp, NULL); | 461 | name = get_file_name (p, endp, NULL); |
462 | if (name) | 462 | if (name) |
463 | { | 463 | { |
464 | mu_sv_load_add_dir (mu_sieve_machine, name); | 464 | mu_i_sv_load_add_dir (mu_sieve_machine, name); |
465 | free (name); | 465 | free (name); |
466 | } | 466 | } |
467 | } | 467 | } | ... | ... |
... | @@ -604,7 +604,7 @@ code_node_cond (struct mu_sieve_machine *mach, struct mu_sieve_node *node) | ... | @@ -604,7 +604,7 @@ code_node_cond (struct mu_sieve_machine *mach, struct mu_sieve_node *node) |
604 | size_t br1; | 604 | size_t br1; |
605 | 605 | ||
606 | tree_code (mach, node->v.cond.expr); | 606 | tree_code (mach, node->v.cond.expr); |
607 | mu_i_sv_code (mach, (sieve_op_t) _mu_sv_instr_brz); | 607 | mu_i_sv_code (mach, (sieve_op_t) _mu_i_sv_instr_brz); |
608 | br1 = mach->pc; | 608 | br1 = mach->pc; |
609 | mu_i_sv_code (mach, (sieve_op_t) 0); | 609 | mu_i_sv_code (mach, (sieve_op_t) 0); |
610 | tree_code (mach, node->v.cond.iftrue); | 610 | tree_code (mach, node->v.cond.iftrue); |
... | @@ -613,7 +613,7 @@ code_node_cond (struct mu_sieve_machine *mach, struct mu_sieve_node *node) | ... | @@ -613,7 +613,7 @@ code_node_cond (struct mu_sieve_machine *mach, struct mu_sieve_node *node) |
613 | { | 613 | { |
614 | size_t br2; | 614 | size_t br2; |
615 | 615 | ||
616 | mu_i_sv_code (mach, (sieve_op_t) _mu_sv_instr_branch); | 616 | mu_i_sv_code (mach, (sieve_op_t) _mu_i_sv_instr_branch); |
617 | br2 = mach->pc; | 617 | br2 = mach->pc; |
618 | mu_i_sv_code (mach, (sieve_op_t) 0); | 618 | mu_i_sv_code (mach, (sieve_op_t) 0); |
619 | 619 | ||
... | @@ -761,7 +761,7 @@ optimize_node_anyof (struct mu_sieve_node *node) | ... | @@ -761,7 +761,7 @@ optimize_node_anyof (struct mu_sieve_node *node) |
761 | static int | 761 | static int |
762 | code_node_anyof (struct mu_sieve_machine *mach, struct mu_sieve_node *node) | 762 | code_node_anyof (struct mu_sieve_machine *mach, struct mu_sieve_node *node) |
763 | { | 763 | { |
764 | return code_node_x_of (mach, node, (sieve_op_t) _mu_sv_instr_brnz); | 764 | return code_node_x_of (mach, node, (sieve_op_t) _mu_i_sv_instr_brnz); |
765 | } | 765 | } |
766 | 766 | ||
767 | /* mu_sieve_node_allof */ | 767 | /* mu_sieve_node_allof */ |
... | @@ -774,7 +774,7 @@ optimize_node_allof (struct mu_sieve_node *node) | ... | @@ -774,7 +774,7 @@ optimize_node_allof (struct mu_sieve_node *node) |
774 | static int | 774 | static int |
775 | code_node_allof (struct mu_sieve_machine *mach, struct mu_sieve_node *node) | 775 | code_node_allof (struct mu_sieve_machine *mach, struct mu_sieve_node *node) |
776 | { | 776 | { |
777 | return code_node_x_of (mach, node, (sieve_op_t) _mu_sv_instr_brz); | 777 | return code_node_x_of (mach, node, (sieve_op_t) _mu_i_sv_instr_brz); |
778 | } | 778 | } |
779 | 779 | ||
780 | /* mu_sieve_node_not */ | 780 | /* mu_sieve_node_not */ |
... | @@ -809,7 +809,7 @@ static int | ... | @@ -809,7 +809,7 @@ static int |
809 | code_node_not (struct mu_sieve_machine *mach, struct mu_sieve_node *node) | 809 | code_node_not (struct mu_sieve_machine *mach, struct mu_sieve_node *node) |
810 | { | 810 | { |
811 | node_code (mach, node->v.node); | 811 | node_code (mach, node->v.node); |
812 | return mu_i_sv_code (mach, (sieve_op_t) _mu_sv_instr_not); | 812 | return mu_i_sv_code (mach, (sieve_op_t) _mu_i_sv_instr_not); |
813 | } | 813 | } |
814 | 814 | ||
815 | static void | 815 | static void |
... | @@ -1230,9 +1230,9 @@ mu_sieve_machine_destroy (mu_sieve_machine_t *pmach) | ... | @@ -1230,9 +1230,9 @@ mu_sieve_machine_destroy (mu_sieve_machine_t *pmach) |
1230 | static void | 1230 | static void |
1231 | sieve_machine_begin (mu_sieve_machine_t mach, const char *file) | 1231 | sieve_machine_begin (mu_sieve_machine_t mach, const char *file) |
1232 | { | 1232 | { |
1233 | mu_sv_register_standard_actions (mach); | 1233 | mu_i_sv_register_standard_actions (mach); |
1234 | mu_sv_register_standard_tests (mach); | 1234 | mu_i_sv_register_standard_tests (mach); |
1235 | mu_sv_register_standard_comparators (mach); | 1235 | mu_i_sv_register_standard_comparators (mach); |
1236 | mu_sieve_machine = mach; | 1236 | mu_sieve_machine = mach; |
1237 | } | 1237 | } |
1238 | 1238 | ||
... | @@ -1292,6 +1292,12 @@ sieve_parse (void) | ... | @@ -1292,6 +1292,12 @@ sieve_parse (void) |
1292 | tree_dump (mu_strerr, sieve_tree, 0); | 1292 | tree_dump (mu_strerr, sieve_tree, 0); |
1293 | } | 1293 | } |
1294 | mu_i_sv_code (mu_sieve_machine, (sieve_op_t) 0); | 1294 | mu_i_sv_code (mu_sieve_machine, (sieve_op_t) 0); |
1295 | |||
1296 | /* Clear location, so that mu_i_sv_locus will do its job. */ | ||
1297 | mu_sieve_machine->locus.mu_file = NULL; | ||
1298 | mu_sieve_machine->locus.mu_line = 0; | ||
1299 | mu_sieve_machine->locus.mu_col = 0; | ||
1300 | |||
1295 | rc = tree_code (mu_sieve_machine, sieve_tree); | 1301 | rc = tree_code (mu_sieve_machine, sieve_tree); |
1296 | if (rc) | 1302 | if (rc) |
1297 | mu_i_sv_error (mu_sieve_machine); | 1303 | mu_i_sv_error (mu_sieve_machine); | ... | ... |
... | @@ -428,7 +428,7 @@ mu_sieve_tag_group_t header_tag_groups[] = { | ... | @@ -428,7 +428,7 @@ mu_sieve_tag_group_t header_tag_groups[] = { |
428 | }; | 428 | }; |
429 | 429 | ||
430 | void | 430 | void |
431 | mu_sv_register_standard_tests (mu_sieve_machine_t mach) | 431 | mu_i_sv_register_standard_tests (mu_sieve_machine_t mach) |
432 | { | 432 | { |
433 | /* true and false are built-ins */ | 433 | /* true and false are built-ins */ |
434 | mu_sieve_register_test (mach, "address", sieve_test_address, | 434 | mu_sieve_register_test (mach, "address", sieve_test_address, | ... | ... |
... | @@ -339,7 +339,7 @@ sieve_print_value (mu_sieve_value_t *val, mu_stream_t str) | ... | @@ -339,7 +339,7 @@ sieve_print_value (mu_sieve_value_t *val, mu_stream_t str) |
339 | } | 339 | } |
340 | 340 | ||
341 | void | 341 | void |
342 | mu_sv_print_value_list (mu_list_t list, mu_stream_t str) | 342 | mu_i_sv_print_value_list (mu_list_t list, mu_stream_t str) |
343 | { | 343 | { |
344 | mu_sieve_value_t val; | 344 | mu_sieve_value_t val; |
345 | 345 | ||
... | @@ -366,7 +366,7 @@ tag_printer (void *item, void *data) | ... | @@ -366,7 +366,7 @@ tag_printer (void *item, void *data) |
366 | } | 366 | } |
367 | 367 | ||
368 | void | 368 | void |
369 | mu_sv_print_tag_list (mu_list_t list, mu_stream_t str) | 369 | mu_i_sv_print_tag_list (mu_list_t list, mu_stream_t str) |
370 | { | 370 | { |
371 | mu_list_foreach (list, tag_printer, str); | 371 | mu_list_foreach (list, tag_printer, str); |
372 | } | 372 | } | ... | ... |
-
Please register or sign in to post a comment