summaryrefslogtreecommitdiffstats
path: root/VNFs/DPPD-PROX/prox_args.c
diff options
context:
space:
mode:
Diffstat (limited to 'VNFs/DPPD-PROX/prox_args.c')
-rw-r--r--VNFs/DPPD-PROX/prox_args.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/VNFs/DPPD-PROX/prox_args.c b/VNFs/DPPD-PROX/prox_args.c
index 9b76a43c..d8c41021 100644
--- a/VNFs/DPPD-PROX/prox_args.c
+++ b/VNFs/DPPD-PROX/prox_args.c
@@ -1019,6 +1019,18 @@ static int get_core_cfg(unsigned sindex, char *str, void *data)
if (STR_EQ(str, "random")) {
return parse_str(targ->rand_str[targ->n_rand_str++], pkey, sizeof(targ->rand_str[0]));
}
+ if (STR_EQ(str, "range")) {
+ int rc = parse_range(&targ->range[targ->n_ranges].min, &targ->range[targ->n_ranges].max, pkey);
+ targ->n_ranges++;
+ return rc;
+ }
+ if (STR_EQ(str, "range_offset")) {
+ if (targ->n_ranges == 0) {
+ set_errf("No range defined previously (use range=...)");
+ return -1;
+ }
+ return parse_int(&targ->range[targ->n_ranges - 1].offset, pkey);
+ }
if (STR_EQ(str, "rand_offset")) {
if (targ->n_rand_str == 0) {
set_errf("No random defined previously (use random=...)");