ofp-util: Make ofputil_encode_set_protocol() able to return failure.
authorBen Pfaff <blp@nicira.com>
Fri, 16 Nov 2012 06:09:07 +0000 (22:09 -0800)
committerBen Pfaff <blp@nicira.com>
Fri, 16 Nov 2012 17:20:21 +0000 (09:20 -0800)
Soon, it's not going to be possible to switch between every possible
protocol on an established OpenFlow connection, yet
ofputil_encode_set_protocol() didn't have a documented way to report such
a problem.  This commit adds a means for reporting and makes its callers
able to handle the problem.

Also, initially make ofputil_encode_set_protocol() fail when the current
and requested protocols are for different OpenFlow versions.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Reviewed-by: Simon Horman <horms@verge.net.au>

No differences found