classifier: Allow classifier_for_each_match() callback to free the rule.
authorBen Pfaff <blp@nicira.com>
Wed, 4 Mar 2009 21:26:19 +0000 (13:26 -0800)
committerBen Pfaff <blp@nicira.com>
Wed, 4 Mar 2009 21:29:05 +0000 (13:29 -0800)
commitc684e3f3c3be00deaa3ea287db86b047d02aebc9
tree06b62f5a3e59310d0793d2c02731e4961788863c
parentf6a851f1d7fae68d19529e94136bb22f32a1ebb9
classifier: Allow classifier_for_each_match() callback to free the rule.

classifier_for_each_match() would segfault if the callback passed in
deleted and freed the rule in question, because it accessed the rule after
calling the callback.  This commit should fix the problem.

Thanks to Natasha for reporting the problem.
lib/classifier.c