diff options
| author | Ben Pfaff <blp@nicira.com> | 2011-06-30 10:04:09 -0700 |
|---|---|---|
| committer | Ben Pfaff <blp@nicira.com> | 2011-06-30 10:04:09 -0700 |
| commit | b4b8c7812bdfdc5a6fda4251453d8e3409486b98 (patch) | |
| tree | df0184912e82dd6897fa4f89cfc0028033a356f4 /utilities/ovs-ofctl.c | |
| parent | 8f93e93c807d3acd06fb3b367276f574164b1a9c (diff) | |
| download | openvswitch-b4b8c7812bdfdc5a6fda4251453d8e3409486b98.tar.gz | |
ofp-util: Simplify iteration through OpenFlow actions.
The existing actions_first() and actions_next() iterator functions are not
much like the other iteration constructs found throughout the Open vSwitch
tree. Also, they only work with actions that have already been validated,
so there are cases where they cannot be used.
This commit adds new macros for iterating through OpenFlow actions, one
for actions that have been validated and one for actions that have not, and
adapts the existing users. The following commit will further refine action
parsing and add more users.
Diffstat (limited to 'utilities/ovs-ofctl.c')
| -rw-r--r-- | utilities/ovs-ofctl.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/utilities/ovs-ofctl.c b/utilities/ovs-ofctl.c index 3d101789d..a6fff256c 100644 --- a/utilities/ovs-ofctl.c +++ b/utilities/ovs-ofctl.c @@ -951,8 +951,7 @@ fte_version_print(const struct fte_version *version) } ds_init(&s); - ofp_print_actions(&s, (const struct ofp_action_header *) version->actions, - version->n_actions * sizeof *version->actions); + ofp_print_actions(&s, version->actions, version->n_actions); printf(" %s\n", ds_cstr(&s)); ds_destroy(&s); } |
