Signed-off-by: Joe Stringer <[email protected]>
---
lib/ofp-parse.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lib/ofp-parse.c b/lib/ofp-parse.c
index eed5a08..0473665 100644
--- a/lib/ofp-parse.c
+++ b/lib/ofp-parse.c
@@ -588,7 +588,8 @@ parse_ofp_meter_mod_str__(struct ofputil_meter_mod *mm,
char *string,
if (error) {
return error;
}
- if (mm->meter.meter_id > OFPM13_MAX) {
+ if (mm->meter.meter_id > OFPM13_MAX
+ || !mm->meter.meter_id) {
return xasprintf("invalid value for %s", name);
}
}
--
1.7.10.4
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev