|
Revision 1811, 1.0 kB
(checked in by jan, 18 months ago)
|
|
fixed the reset of the conditional cache in mod-magnet
|
-
Property svn:eol-style set to
native
|
| Line | |
|---|
| 1 | #ifndef _CONFIG_PARSER_H_ |
|---|
| 2 | #define _CONFIG_PARSER_H_ |
|---|
| 3 | |
|---|
| 4 | #include "settings.h" |
|---|
| 5 | #include "server.h" |
|---|
| 6 | #include "array.h" |
|---|
| 7 | #include "buffer.h" |
|---|
| 8 | |
|---|
| 9 | typedef struct { |
|---|
| 10 | server *srv; |
|---|
| 11 | int ok; |
|---|
| 12 | array *all_configs; |
|---|
| 13 | buffer_ptr *configs_stack; /* to parse nested block */ |
|---|
| 14 | data_config *current; /* current started with { */ |
|---|
| 15 | buffer *basedir; |
|---|
| 16 | } config_t; |
|---|
| 17 | |
|---|
| 18 | LI_API void * configparserAlloc(void *(*mallocProc)(size_t)); |
|---|
| 19 | LI_API void configparserFree(void *p, void (*freeProc)(void*)); |
|---|
| 20 | LI_API void configparser(void *yyp, int yymajor, buffer *yyminor, config_t *ctx); |
|---|
| 21 | LI_API int config_parse_file(server *srv, config_t *context, const char *fn); |
|---|
| 22 | LI_API int config_parse_cmd(server *srv, config_t *context, const char *cmd); |
|---|
| 23 | LI_API data_unset * configparser_merge_data(data_unset *op1, const data_unset *op2); |
|---|
| 24 | LI_API void config_cond_cache_reset(server *srv, connection *con); |
|---|
| 25 | LI_API void config_cond_cache_reset_item(server *srv, connection *con, comp_key_t item); |
|---|
| 26 | |
|---|
| 27 | #define config_cond_cache_reset_all_items(srv, con) \ |
|---|
| 28 | config_cond_cache_reset_item(srv, con, COMP_LAST_ELEMENT); |
|---|
| 29 | |
|---|
| 30 | #endif |
|---|