Changeset 057e0c6fdd21f0c4e9158d3ae149de09dd80dfd9
- Timestamp:
- 11/22/08 16:41:21
(4 years ago)
- Author:
- Theo Schlossnagle <jesus@omniti.com>
- git-committer:
- Theo Schlossnagle <jesus@omniti.com> 1227372081 +0000
- git-parent:
[839ed4b45ead30b4c16f8196190d8e185d1ef116]
- git-author:
- Theo Schlossnagle <jesus@omniti.com> 1227372081 +0000
- Message:
change noit_conf_boolean to noit_conf... more sense. refs #34
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| r7180374 |
r057e0c6 |
|
| 115 | 115 | int no_oncheck = 0; |
|---|
| 116 | 116 | int period = 0, timeout = 0; |
|---|
| 117 | | noit_conf_boolean disabled = noit_false, busted = noit_false; |
|---|
| | 117 | noit_boolean disabled = noit_false, busted = noit_false; |
|---|
| 118 | 118 | uuid_t uuid, out_uuid; |
|---|
| 119 | 119 | noit_hash_table *options; |
|---|
| rdb656f3 |
r057e0c6 |
|
| 429 | 429 | } |
|---|
| 430 | 430 | int noit_conf_get_boolean(noit_conf_section_t section, |
|---|
| 431 | | const char *path, noit_conf_boolean *value) { |
|---|
| | 431 | const char *path, noit_boolean *value) { |
|---|
| 432 | 432 | char *str; |
|---|
| 433 | 433 | if(_noit_conf_get_string(section,NULL,path,&str)) { |
|---|
| … | … | |
| 441 | 441 | } |
|---|
| 442 | 442 | int noit_conf_set_boolean(noit_conf_section_t section, |
|---|
| 443 | | const char *path, noit_conf_boolean value) { |
|---|
| | 443 | const char *path, noit_boolean value) { |
|---|
| 444 | 444 | if(value == noit_true) |
|---|
| 445 | 445 | return noit_conf_set_string(section,path,"true"); |
|---|
| … | … | |
| 662 | 662 | char name[256], type[256], path[256]; |
|---|
| 663 | 663 | noit_hash_table *config; |
|---|
| 664 | | noit_conf_boolean disabled; |
|---|
| | 664 | noit_boolean disabled; |
|---|
| 665 | 665 | |
|---|
| 666 | 666 | if(!noit_conf_get_stringbuf(log_configs[i], |
|---|
| rdcd539d |
r057e0c6 |
|
| 13 | 13 | #include <uuid/uuid.h> |
|---|
| 14 | 14 | |
|---|
| 15 | | typedef enum { noit_false = 0, noit_true } noit_conf_boolean; |
|---|
| 16 | 15 | typedef void * noit_conf_section_t; |
|---|
| 17 | 16 | |
|---|
| … | … | |
| 57 | 56 | const char *path, float *value); |
|---|
| 58 | 57 | API_EXPORT(int) noit_conf_get_boolean(noit_conf_section_t section, |
|---|
| 59 | | const char *path, noit_conf_boolean *value); |
|---|
| | 58 | const char *path, noit_boolean *value); |
|---|
| 60 | 59 | API_EXPORT(int) |
|---|
| 61 | 60 | noit_conf_get_uuid(noit_conf_section_t section, |
|---|
| … | … | |
| 69 | 68 | const char *path, float value); |
|---|
| 70 | 69 | API_EXPORT(int) noit_conf_set_boolean(noit_conf_section_t section, |
|---|
| 71 | | const char *path, noit_conf_boolean value); |
|---|
| | 70 | const char *path, noit_boolean value); |
|---|
| 72 | 71 | |
|---|
| 73 | 72 | API_EXPORT(int) |
|---|
| r7180374 |
r057e0c6 |
|
| 235 | 235 | xmlXPathObjectPtr pobj = NULL; |
|---|
| 236 | 236 | xmlNodePtr node = NULL; |
|---|
| 237 | | noit_conf_boolean creating_new = noit_false; |
|---|
| | 237 | noit_boolean creating_new = noit_false; |
|---|
| 238 | 238 | |
|---|
| 239 | 239 | if(closure) { |
|---|
| r451a0e0 |
r057e0c6 |
|
| 247 | 247 | #endif |
|---|
| 248 | 248 | |
|---|
| 249 | | #endif |
|---|
| | 249 | typedef enum { noit_false = 0, noit_true } noit_boolean; |
|---|
| | 250 | |
|---|
| | 251 | #endif |
|---|
| rf921b22 |
r057e0c6 |
|
| 142 | 142 | } |
|---|
| 143 | 143 | |
|---|
| 144 | | static noit_conf_boolean |
|---|
| | 144 | static noit_boolean |
|---|
| 145 | 145 | noit_apply_filterrule(pcre *p, pcre_extra *pe, const char *subj) { |
|---|
| 146 | 146 | int rc, ovector[30]; |
|---|
| … | … | |
| 150 | 150 | return noit_false; |
|---|
| 151 | 151 | } |
|---|
| 152 | | noit_conf_boolean |
|---|
| | 152 | noit_boolean |
|---|
| 153 | 153 | noit_apply_filterset(const char *filterset, |
|---|
| 154 | 154 | noit_check_t *check, |
|---|
| rf921b22 |
r057e0c6 |
|
| 19 | 19 | noit_refresh_filtersets(); |
|---|
| 20 | 20 | |
|---|
| 21 | | API_EXPORT(noit_conf_boolean) |
|---|
| | 21 | API_EXPORT(noit_boolean) |
|---|
| 22 | 22 | noit_apply_filterset(const char *filterset, |
|---|
| 23 | 23 | noit_check_t *check, |
|---|
| r6bb9ef8 |
r057e0c6 |
|
| 292 | 292 | int backlog; |
|---|
| 293 | 293 | eventer_func_t f; |
|---|
| 294 | | noit_conf_boolean ssl; |
|---|
| | 294 | noit_boolean ssl; |
|---|
| 295 | 295 | noit_hash_table *sslconfig, *config; |
|---|
| 296 | 296 | |
|---|