ofproto: Make taking rule reference conditional on lookup.
authorJarno Rajahalme <jrajahalme@nicira.com>
Thu, 24 Apr 2014 15:21:49 +0000 (08:21 -0700)
committerJarno Rajahalme <jrajahalme@nicira.com>
Thu, 24 Apr 2014 15:25:45 +0000 (08:25 -0700)
commit1a7c0cd710e19db3ff85606dbfd5fdad964a1eea
tree6f16eb5802c6dc394fba02bf7304a0010e26fdab
parentf416c8d616012b0369cd53d43960fc9da166229b
ofproto: Make taking rule reference conditional on lookup.

Prior to this paths the rule lookup functions have always taken a
reference on the found rule before returning.  Make this conditional,
so that unnecessary refs/unrefs can be avoided in a later patch.

Signed-off-by: Jarno Rajahalme <jrajahalme@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
ofproto/ofproto-dpif-xlate.c
ofproto/ofproto-dpif.c
ofproto/ofproto-dpif.h