History

openvswitch: Avoid assigning a NULL pointer to flow actions.

Flow SET can accept an empty set of actions, with the intended semantics of leaving existing actions unmodified. This seems to have been brokin after OVS 1.7, as we have assigned the flow's actions pointer to NULL in this case, but we never check for the NULL pointer later on. This patch restores the intended behavior and documents it in the include/linux/openvswitch.h.

Jarno Rajahalme committed 12 years ago

Commit be52c9e1 parent 1139e242 files · +11 −7Browse files

Showing the changes to include/uapi/linux (1 of 2 files). Show all

Unified · Split

include/uapi/linux/openvswitch.h+3−1
@@ -395,7 +395,9 @@ struct ovs_key_nd { · 394 unmodified lines
395 * @OVS_FLOW_ATTR_ACTIONS: Nested %OVS_ACTION_ATTR_* attributes specifying395 * @OVS_FLOW_ATTR_ACTIONS: Nested %OVS_ACTION_ATTR_* attributes specifying
396 * the actions to take for packets that match the key. Always present in396 * the actions to take for packets that match the key. Always present in
397 * notifications. Required for %OVS_FLOW_CMD_NEW requests, optional for397 * notifications. Required for %OVS_FLOW_CMD_NEW requests, optional for
398 * %OVS_FLOW_CMD_SET requests.398 * %OVS_FLOW_CMD_SET requests. An %OVS_FLOW_CMD_SET without
399 * %OVS_FLOW_ATTR_ACTIONS will not modify the actions. To clear the actions,
400 * an %OVS_FLOW_ATTR_ACTIONS without any nested attributes must be given.
399 * @OVS_FLOW_ATTR_STATS: &struct ovs_flow_stats giving statistics for this401 * @OVS_FLOW_ATTR_STATS: &struct ovs_flow_stats giving statistics for this
400 * flow. Present in notifications if the stats would be nonzero. Ignored in402 * flow. Present in notifications if the stats would be nonzero. Ignored in
401 * requests.403 * requests.

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t