* mailbox2/header.c(header_aget_value): Base on discussion with Sergey
if the call fails no memory should be allocated and the return status should be return i.e. status != 0. * sieve/Makefile.am: To EXTRA_DIST add md5-rsa.{c,h}.
Showing
3 changed files
with
16 additions
and
28 deletions
1 | 2001-08-24 Alain Magloire | ||
2 | |||
3 | * sieve/Makefile.am: To EXTRA_DIST add md5-rsa.{c,h}. | ||
4 | |||
5 | * mailbox2/header.c(header_aget_value): Base on discussion with Sergey | ||
6 | if the call fails no memory should be allocated and the return status | ||
7 | should be return i.e. status != 0. | ||
8 | |||
1 | 2001-08-23 Sergey Poznyakoff | 9 | 2001-08-23 Sergey Poznyakoff |
2 | 10 | ||
3 | * mail/msgset.y: Fixed erroneous call to msgset_select | 11 | * mail/msgset.y: Fixed erroneous call to msgset_select |
... | @@ -3042,4 +3050,4 @@ | ... | @@ -3042,4 +3050,4 @@ |
3042 | 1999-09-10 Jeff Bailey | 3050 | 1999-09-10 Jeff Bailey |
3043 | 3051 | ||
3044 | * */*: Accomidate directory rearrange | 3052 | * */*: Accomidate directory rearrange |
3045 | 3053 | ... | ... |
... | @@ -102,16 +102,9 @@ header_aget_value (header_t header, const char *name, char **pvalue) | ... | @@ -102,16 +102,9 @@ header_aget_value (header_t header, const char *name, char **pvalue) |
102 | if (value == NULL) | 102 | if (value == NULL) |
103 | return MU_ERROR_NO_MEMORY; | 103 | return MU_ERROR_NO_MEMORY; |
104 | header_get_value (header, name, value, n + 1, NULL); | 104 | header_get_value (header, name, value, n + 1, NULL); |
105 | *pvalue = value; | ||
105 | } | 106 | } |
106 | else | 107 | return status; |
107 | { | ||
108 | value = malloc (1); | ||
109 | if (value == NULL) | ||
110 | return MU_ERROR_NO_MEMORY; | ||
111 | *value = '\0'; | ||
112 | } | ||
113 | *pvalue = value; | ||
114 | return 0; | ||
115 | } | 108 | } |
116 | 109 | ||
117 | int | 110 | int |
... | @@ -145,16 +138,9 @@ header_aget_field_name (header_t header, size_t num, char **pvalue) | ... | @@ -145,16 +138,9 @@ header_aget_field_name (header_t header, size_t num, char **pvalue) |
145 | if (value == NULL) | 138 | if (value == NULL) |
146 | return MU_ERROR_NO_MEMORY; | 139 | return MU_ERROR_NO_MEMORY; |
147 | header_get_field_name (header, num, value, n + 1, NULL); | 140 | header_get_field_name (header, num, value, n + 1, NULL); |
141 | *pvalue = value; | ||
148 | } | 142 | } |
149 | else | 143 | return status; |
150 | { | ||
151 | value = malloc (1); | ||
152 | if (value == NULL) | ||
153 | return MU_ERROR_NO_MEMORY; | ||
154 | *value = '\0'; | ||
155 | } | ||
156 | *pvalue = value; | ||
157 | return 0; | ||
158 | } | 144 | } |
159 | 145 | ||
160 | int | 146 | int |
... | @@ -179,15 +165,8 @@ header_aget_field_value (header_t header, size_t num, char **pvalue) | ... | @@ -179,15 +165,8 @@ header_aget_field_value (header_t header, size_t num, char **pvalue) |
179 | if (value == NULL) | 165 | if (value == NULL) |
180 | return MU_ERROR_NO_MEMORY; | 166 | return MU_ERROR_NO_MEMORY; |
181 | header_get_field_value (header, num, value, n + 1, NULL); | 167 | header_get_field_value (header, num, value, n + 1, NULL); |
168 | *pvalue = value; | ||
182 | } | 169 | } |
183 | else | ||
184 | { | ||
185 | value = malloc (1); | ||
186 | if (value == NULL) | ||
187 | return MU_ERROR_NO_MEMORY; | ||
188 | *value = '\0'; | ||
189 | } | ||
190 | *pvalue = value; | ||
191 | return status; | 170 | return status; |
192 | } | 171 | } |
193 | 172 | ... | ... |
... | @@ -15,7 +15,7 @@ DISTCLEANFILES= | ... | @@ -15,7 +15,7 @@ DISTCLEANFILES= |
15 | MAINTAINERCLEANFILES=$(BUILT_SOURCES) | 15 | MAINTAINERCLEANFILES=$(BUILT_SOURCES) |
16 | EXTRA_DIST = \ | 16 | EXTRA_DIST = \ |
17 | $(BUILT_SOURCES) \ | 17 | $(BUILT_SOURCES) \ |
18 | addr-lex.l addr.y gram-sieve.y sieve-gram.y sieve-lex.l | 18 | addr-lex.l addr.y gram-sieve.y sieve-gram.y sieve-lex.l md5-rsa.h |
19 | 19 | ||
20 | bin_PROGRAMS = sieve | 20 | bin_PROGRAMS = sieve |
21 | 21 | ||
... | @@ -26,6 +26,7 @@ SRC = \ | ... | @@ -26,6 +26,7 @@ SRC = \ |
26 | imparse.c \ | 26 | imparse.c \ |
27 | interp.c \ | 27 | interp.c \ |
28 | message.c \ | 28 | message.c \ |
29 | md5-rsa.c \ | ||
29 | parseaddr.c \ | 30 | parseaddr.c \ |
30 | script.c \ | 31 | script.c \ |
31 | sieve-lex.c \ | 32 | sieve-lex.c \ | ... | ... |
-
Please register or sign in to post a comment