ofproto-dpif: Fix up user specifying wrong bridge on "ofproto/trace".
authorBen Pfaff <blp@nicira.com>
Wed, 6 Mar 2013 00:48:21 +0000 (16:48 -0800)
committerBen Pfaff <blp@nicira.com>
Fri, 8 Mar 2013 18:34:59 +0000 (10:34 -0800)
commitc3480393c283d2df630edcf56e7beaf1cf481312
tree4187af238d09b0c1488f1c0b938e3c7314c1c41d
parente2cf1363d629c4e9c202bd5be43e75a5fafbab59
ofproto-dpif: Fix up user specifying wrong bridge on "ofproto/trace".

If there is more than one bridge, then it's easy to specify the wrong one
on an ofproto/trace command.  Previously, this would produce surprising
results.  With this commit, "ofproto/trace" should silently fix up the
problem.

It would be nice to not require the user to specify a bridge at all, but
it's theoretically possible to have more than one backer, in which case we
need some way to distinguish, and a bridge name is as good an identifier
as we have.  We could ask the user to specify the datapath_type, I guess,
but that's a less familiar name to most users and it would be a somewhat
gratuitous change in synatx for ofproto/trace.

Bug #15419.
Reported-by: Paul Ingram <paul@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ofproto/ofproto-dpif.c