ofproto: Check ofproto_port_query_by_name() return value when adding port.
authorBen Pfaff <blp@nicira.com>
Tue, 19 Mar 2013 20:30:33 +0000 (13:30 -0700)
committerBen Pfaff <blp@nicira.com>
Mon, 11 Nov 2013 16:42:08 +0000 (08:42 -0800)
commit17f69db575069b403cfaf24e9e00c0ce37195250
treef60cb5a8985a728c6b7640dd8f2928686c637616
parentfb668e3a13eaa07bbb8bc50cbee1d201051b779c
ofproto: Check ofproto_port_query_by_name() return value when adding port.

Otherwise, if the port add succeeds but the query that looks up the port
number fails, then ofproto_port_add() would return zero as the OpenFlow
port number and ignore the error.

Reported-by: Guolin Yang <gyang@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
AUTHORS
ofproto/ofproto.c