From: Ben Pfaff Date: Thu, 11 Nov 2010 18:25:34 +0000 (-0800) Subject: classifier: Pass correct member to CONTAINER_OF in cls_table_next_rule(). X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eacf6385a92c86a81f4d47cd8d44e80d9805be72;p=openvswitch classifier: Pass correct member to CONTAINER_OF in cls_table_next_rule(). Fixes a segmentation fault in uses of CLASSIFIER_FOR_EACH_EXACT_RULE. Reported-by: Derek Cormier --- diff --git a/lib/classifier.c b/lib/classifier.c index 85c3c45a..38c4d25c 100644 --- a/lib/classifier.c +++ b/lib/classifier.c @@ -91,7 +91,7 @@ struct cls_rule * cls_table_next_rule(const struct cls_table *table, const struct cls_rule *rule) { struct cls_rule *next - = CONTAINER_OF(rule->list.next, struct cls_rule, hmap_node); + = CONTAINER_OF(rule->list.next, struct cls_rule, list); return (next->priority < rule->priority ? next