summaryrefslogtreecommitdiff
path: root/ofproto/ofproto-dpif-trace.c
diff options
context:
space:
mode:
authorAshish Varma <ashishvarma.ovs@gmail.com>2019-02-04 15:34:34 -0800
committerBen Pfaff <blp@ovn.org>2019-02-04 15:54:56 -0800
commit3782d8efb5ecf8bf9bfa7c20629abe3b4e2e0a15 (patch)
tree5513e95b7c45179f195359fef383339d963da81d /ofproto/ofproto-dpif-trace.c
parentada5efce102d6191e5c66fc385ba52a2d340ef50 (diff)
downloadopenvswitch-3782d8efb5ecf8bf9bfa7c20629abe3b4e2e0a15.tar.gz
ofproto-dpif-trace: Fix for the segmentation fault in ofproto_trace().
Added the check for NULL in "next_ct_states" argument passed to the "ofproto_trace()" function. Under normal scenario, this is non-NULL. A NULL "next_ct_states" argument is passed from the "upcall_xlate()" function on encountering XLATE_RECURSION_TOO_DEEP or XLATE_TOO_MANY_RESUBMITS error. VMware-BZ: #2282287 Signed-off-by: Ashish Varma <ashishvarma.ovs@gmail.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'ofproto/ofproto-dpif-trace.c')
-rw-r--r--ofproto/ofproto-dpif-trace.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ofproto/ofproto-dpif-trace.c b/ofproto/ofproto-dpif-trace.c
index eca61cee2..4a981e1e4 100644
--- a/ofproto/ofproto-dpif-trace.c
+++ b/ofproto/ofproto-dpif-trace.c
@@ -740,7 +740,7 @@ ofproto_trace(struct ofproto_dpif *ofproto, const struct flow *flow,
ds_put_format(output, "\nrecirc(%#"PRIx32")",
recirc_node->recirc_id);
- if (recirc_node->type == OFT_RECIRC_CONNTRACK) {
+ if (next_ct_states && recirc_node->type == OFT_RECIRC_CONNTRACK) {
uint32_t ct_state;
if (ovs_list_is_empty(next_ct_states)) {
ct_state = CS_TRACKED | CS_NEW;