OLD | NEW |
1 /* conf_api.c */ | 1 /* conf_api.c */ |
2 /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 * All rights reserved. | 3 * All rights reserved. |
4 * | 4 * |
5 * This package is an SSL implementation written | 5 * This package is an SSL implementation written |
6 * by Eric Young (eay@cryptsoft.com). | 6 * by Eric Young (eay@cryptsoft.com). |
7 * The implementation was written so as to conform with Netscapes SSL. | 7 * The implementation was written so as to conform with Netscapes SSL. |
8 * | 8 * |
9 * This library is free for commercial and non-commercial use as long as | 9 * This library is free for commercial and non-commercial use as long as |
10 * the following conditions are aheared to. The following conditions | 10 * the following conditions are aheared to. The following conditions |
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
218 { | 218 { |
219 return 0; | 219 return 0; |
220 } | 220 } |
221 return 1; | 221 return 1; |
222 } | 222 } |
223 | 223 |
224 void _CONF_free_data(CONF *conf) | 224 void _CONF_free_data(CONF *conf) |
225 { | 225 { |
226 if (conf == NULL || conf->data == NULL) return; | 226 if (conf == NULL || conf->data == NULL) return; |
227 | 227 |
228 lh_CONF_VALUE_down_load(conf->data)=0; /* evil thing to make | |
229 * sure the 'OPENSSL_free()' works as | |
230 * expected */ | |
231 lh_CONF_VALUE_doall_arg(conf->data, | 228 lh_CONF_VALUE_doall_arg(conf->data, |
232 LHASH_DOALL_ARG_FN(value_free_hash), | 229 LHASH_DOALL_ARG_FN(value_free_hash), |
233 LHASH_OF(CONF_VALUE), conf->data); | 230 LHASH_OF(CONF_VALUE), conf->data); |
234 | 231 |
235 /* We now have only 'section' entries in the hash table. | 232 /* We now have only 'section' entries in the hash table. |
236 * Due to problems with */ | 233 * Due to problems with */ |
237 | 234 |
238 lh_CONF_VALUE_doall(conf->data, LHASH_DOALL_FN(value_free_stack)); | 235 lh_CONF_VALUE_doall(conf->data, LHASH_DOALL_FN(value_free_stack)); |
239 lh_CONF_VALUE_free(conf->data); | 236 lh_CONF_VALUE_free(conf->data); |
240 } | 237 } |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
292 if (!ok) | 289 if (!ok) |
293 { | 290 { |
294 if (sk != NULL) sk_CONF_VALUE_free(sk); | 291 if (sk != NULL) sk_CONF_VALUE_free(sk); |
295 if (v != NULL) OPENSSL_free(v); | 292 if (v != NULL) OPENSSL_free(v); |
296 v=NULL; | 293 v=NULL; |
297 } | 294 } |
298 return(v); | 295 return(v); |
299 } | 296 } |
300 | 297 |
301 IMPLEMENT_STACK_OF(CONF_VALUE) | 298 IMPLEMENT_STACK_OF(CONF_VALUE) |
OLD | NEW |