ofproto/trace: Use final flow to compute "Relevant fields".
authorAlex Wang <alexw@nicira.com>
Thu, 9 Jan 2014 00:52:12 +0000 (16:52 -0800)
committerBen Pfaff <blp@nicira.com>
Thu, 9 Jan 2014 01:00:34 +0000 (17:00 -0800)
Commit bcd2633a (ofproto-dpif: Store relevant fields for wildcarding
in facet.) introduced the bug that uses original input flow as final
flow to compute the "Relevant fields" in ofproto/trace ouput.  This
commit fixes this bug.

Signed-off-by: Alex Wang <alexw@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ofproto/ofproto-dpif.c

index a3fd792..03f7840 100644 (file)
@@ -3870,7 +3870,7 @@ ofproto_trace(struct ofproto_dpif *ofproto, const struct flow *flow,
         ds_put_char(ds, '\n');
         trace_format_flow(ds, 0, "Final flow", &trace);
 
-        match_init(&match, flow, &trace.xout.wc);
+        match_init(&match, &trace.flow, &trace.xout.wc);
         ds_put_cstr(ds, "Relevant fields: ");
         match_format(&match, ds, OFP_DEFAULT_PRIORITY);
         ds_put_char(ds, '\n');