diff options
Diffstat (limited to 'plugins/utils.h')
| -rw-r--r-- | plugins/utils.h | 31 |
1 files changed, 16 insertions, 15 deletions
diff --git a/plugins/utils.h b/plugins/utils.h index c76b3216..f939e337 100644 --- a/plugins/utils.h +++ b/plugins/utils.h | |||
| @@ -16,6 +16,8 @@ suite of plugins. */ | |||
| 16 | /* now some functions etc are being defined in ../lib/utils_base.c */ | 16 | /* now some functions etc are being defined in ../lib/utils_base.c */ |
| 17 | #include "utils_base.h" | 17 | #include "utils_base.h" |
| 18 | 18 | ||
| 19 | #include <stdbool.h> | ||
| 20 | |||
| 19 | 21 | ||
| 20 | #ifdef NP_EXTRA_OPTS | 22 | #ifdef NP_EXTRA_OPTS |
| 21 | /* Include extra-opts functions if compiled in */ | 23 | /* Include extra-opts functions if compiled in */ |
| @@ -34,21 +36,22 @@ extern time_t start_time, end_time; | |||
| 34 | 36 | ||
| 35 | /* Test input types */ | 37 | /* Test input types */ |
| 36 | 38 | ||
| 37 | int is_integer (char *); | 39 | bool is_integer (char *); |
| 38 | int is_intpos (char *); | 40 | bool is_intpos (char *); |
| 39 | int is_intneg (char *); | 41 | bool is_intneg (char *); |
| 40 | int is_intnonneg (char *); | 42 | bool is_intnonneg (char *); |
| 41 | int is_intpercent (char *); | 43 | bool is_intpercent (char *); |
| 42 | int is_uint64(char *number, uint64_t *target); | 44 | bool is_uint64(char *number, uint64_t *target); |
| 43 | int is_int64(char *number, int64_t *target); | 45 | bool is_int64(char *number, int64_t *target); |
| 44 | 46 | ||
| 45 | int is_numeric (char *); | 47 | bool is_numeric (char *); |
| 46 | int is_positive (char *); | 48 | bool is_positive (char *); |
| 47 | int is_negative (char *); | 49 | bool is_negative (char *); |
| 48 | int is_nonnegative (char *); | 50 | bool is_nonnegative (char *); |
| 49 | int is_percentage (char *); | 51 | bool is_percentage (char *); |
| 52 | bool is_percentage_expression (const char[]); | ||
| 50 | 53 | ||
| 51 | int is_option (char *); | 54 | bool is_option (char *); |
| 52 | 55 | ||
| 53 | /* Generalized timer that will do milliseconds if available */ | 56 | /* Generalized timer that will do milliseconds if available */ |
| 54 | #ifndef HAVE_STRUCT_TIMEVAL | 57 | #ifndef HAVE_STRUCT_TIMEVAL |
| @@ -106,8 +109,6 @@ char *sperfdata (const char *, double, const char *, char *, char *, | |||
| 106 | char *sperfdata_int (const char *, int, const char *, char *, char *, | 109 | char *sperfdata_int (const char *, int, const char *, char *, char *, |
| 107 | int, int, int, int); | 110 | int, int, int, int); |
| 108 | 111 | ||
| 109 | int open_max (void); | ||
| 110 | |||
| 111 | /* The idea here is that, although not every plugin will use all of these, | 112 | /* The idea here is that, although not every plugin will use all of these, |
| 112 | most will or should. Therefore, for consistency, these very common | 113 | most will or should. Therefore, for consistency, these very common |
| 113 | options should have only these meanings throughout the overall suite */ | 114 | options should have only these meanings throughout the overall suite */ |
