flow: Fix hypothetical memory leak in miniflow_move().
authorBen Pfaff <blp@nicira.com>
Wed, 4 Sep 2013 19:33:06 +0000 (12:33 -0700)
committerBen Pfaff <blp@nicira.com>
Wed, 4 Sep 2013 19:59:34 +0000 (12:59 -0700)
commitcc1a2dcbba4dac352a294aef06b0131e6382d5b5
tree29cf4d688f564f54d2937ec655f2a1a627c47001
parent3ef7ad56addedfea91d8653883356f15f051ba87
flow: Fix hypothetical memory leak in miniflow_move().

Ordinarily a miniflow will use its inline_values if its values can fit, but
there is nothing to prevent a small number of values from being stored
in malloc()'d memory.  If this happened, then miniflow_move() would leak
memory.  This commit fixes the problem.

This is a hypothetical problem.  I haven't seen it in practice.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
lib/flow.c