dpif: Don't clear argument in dp_enumerate_types().
authorBen Pfaff <blp@nicira.com>
Tue, 2 Dec 2014 18:50:38 +0000 (10:50 -0800)
committerBen Pfaff <blp@nicira.com>
Tue, 2 Dec 2014 19:26:13 +0000 (11:26 -0800)
commit5b5b11ea7b9bfe8983f2449c3bb14f257a84f4a3
tree0824134afca9353aeace7d315318f8d52499ef1c
parent962f9fa4ce21fbe5b73b75d7bc5c2d45a8b08c69
dpif: Don't clear argument in dp_enumerate_types().

All but one of the callers of dp_enumerate_types() hands it an sset that is
known to be empty.  The one exception is the implementation of the
ofproto-provider 'enumerate_types' function in ofproto-dpif.  That function
isn't supposed to clear the existing contents of the sset passed in.
Therefore, this commit changes dp_enumerate_types() to not clear the sset
before it adds new members.

The ofproto-provider comment wasn't clear about the desired behavior so
this commit also clarifies that.

Reported-by: Zoltán Balogh <zoltan.balogh@ericsson.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
AUTHORS
lib/dpif.c
ofproto/ofproto-provider.h