projects
/
cascardo
/
ovs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
ofp-actions: Assert variable actions have len>0.
[cascardo/ovs.git]
/
lib
/
ofp-actions.c
diff --git
a/lib/ofp-actions.c
b/lib/ofp-actions.c
index
905469b
..
702575d
100644
(file)
--- a/
lib/ofp-actions.c
+++ b/
lib/ofp-actions.c
@@
-7405,7
+7405,7
@@
ofpact_finish(struct ofpbuf *ofpacts, struct ofpact *ofpact)
ovs_assert(ofpact == ofpacts->header);
len = (char *) ofpbuf_tail(ofpacts) - (char *) ofpact;
- ovs_assert(len <= UINT16_MAX);
+ ovs_assert(len
> 0 && len
<= UINT16_MAX);
ofpact->len = len;
ofpbuf_padto(ofpacts, OFPACT_ALIGN(ofpacts->size));
}