summaryrefslogtreecommitdiffstats
path: root/plugins/utils.h
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/utils.h')
-rw-r--r--plugins/utils.h31
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
37int is_integer (char *); 39bool is_integer (char *);
38int is_intpos (char *); 40bool is_intpos (char *);
39int is_intneg (char *); 41bool is_intneg (char *);
40int is_intnonneg (char *); 42bool is_intnonneg (char *);
41int is_intpercent (char *); 43bool is_intpercent (char *);
42int is_uint64(char *number, uint64_t *target); 44bool is_uint64(char *number, uint64_t *target);
43int is_int64(char *number, int64_t *target); 45bool is_int64(char *number, int64_t *target);
44 46
45int is_numeric (char *); 47bool is_numeric (char *);
46int is_positive (char *); 48bool is_positive (char *);
47int is_negative (char *); 49bool is_negative (char *);
48int is_nonnegative (char *); 50bool is_nonnegative (char *);
49int is_percentage (char *); 51bool is_percentage (char *);
52bool is_percentage_expression (const char[]);
50 53
51int is_option (char *); 54bool 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 *,
106char *sperfdata_int (const char *, int, const char *, char *, char *, 109char *sperfdata_int (const char *, int, const char *, char *, char *,
107 int, int, int, int); 110 int, int, int, int);
108 111
109int 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 */