blob: 5fcfb73ae0e20d6c8d1393197be701692df4d204 [file] [log] [blame]
From javier.martinez@collabora.co.uk Thu Jun 6 03:26:36 2013
From: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Date: Thu, 6 Jun 2013 12:25:54 +0200
Subject: [PATCH 6/6] netfilter: nfdbus: don't try to erase same node twice
To: Greg KH <gregkh@linuxfoundation.org>
Cc: ltsi-dev@lists.linuxfoundation.org, Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Message-ID: <1370514354-19114-7-git-send-email-javier.martinez@collabora.co.uk>
bus_matchmaker_remove_name() iterates over the matchmaker tree
nodes to remove the name that has been lost.
But the loop was not ended and it tried to remove the same node
twice on the next iteration causing a NULL pointer deference error.
Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
---
net/bus/nfdbus/matchrule.c | 1 +
1 file changed, 1 insertion(+)
--- a/net/bus/nfdbus/matchrule.c
+++ b/net/bus/nfdbus/matchrule.c
@@ -1159,6 +1159,7 @@ void bus_matchmaker_remove_name(struct b
rb_erase(&data->node, &matchmaker->names);
kfree(data->name);
kfree(data);
+ node = NULL;
}
}