summaryrefslogtreecommitdiffstats
path: root/lib/utils_base.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/utils_base.h')
-rw-r--r--lib/utils_base.h18
1 files changed, 13 insertions, 5 deletions
diff --git a/lib/utils_base.h b/lib/utils_base.h
index b6eb57e..6a8af19 100644
--- a/lib/utils_base.h
+++ b/lib/utils_base.h
@@ -2,6 +2,7 @@
2#define _UTILS_BASE_ 2#define _UTILS_BASE_
3/* Header file for nagios plugins utils_base.c */ 3/* Header file for nagios plugins utils_base.c */
4 4
5
5/* This file holds header information for thresholds - use this in preference to 6/* This file holds header information for thresholds - use this in preference to
6 individual plugin logic */ 7 individual plugin logic */
7 8
@@ -46,6 +47,12 @@ typedef struct state_key_struct {
46 state_data *state_data; 47 state_data *state_data;
47 } state_key; 48 } state_key;
48 49
50typedef struct np_struct {
51 char *plugin_name;
52 state_key *state;
53 char **expanded_argv;
54 } nagios_plugin;
55
49range *parse_range_string (char *); 56range *parse_range_string (char *);
50int _set_thresholds(thresholds **, char *, char *); 57int _set_thresholds(thresholds **, char *, char *);
51void set_thresholds(thresholds **, char *, char *); 58void set_thresholds(thresholds **, char *, char *);
@@ -86,10 +93,11 @@ char *np_extract_value(const char*, const char*, char);
86#define np_extract_ntpvar(l, n) np_extract_value(l, n, ',') 93#define np_extract_ntpvar(l, n) np_extract_value(l, n, ',')
87 94
88 95
89char *np_state_generate_key(char **); 96void np_state_init(char *, int);
90state_key *np_state_init(char *, char *, int); 97state_data *np_state_read();
91state_data *np_state_read(state_key *); 98void np_state_write_string(time_t *, char *);
92void np_state_write_string(state_key *, time_t *, char *); 99
93void np_state_cleanup(state_key *); 100void np_init(char *);
101void np_cleanup();
94 102
95#endif /* _UTILS_BASE_ */ 103#endif /* _UTILS_BASE_ */