Bug 25697 - Fix memory leak in policy reload
[platform/upstream/dbus.git] / bus / bus.c
index ede6dda..b370f92 100644 (file)
--- a/bus/bus.c
+++ b/bus/bus.c
@@ -433,6 +433,8 @@ process_config_every_time (BusContext      *context,
   /* get our limits and timeout lengths */
   bus_config_parser_get_limits (parser, &context->limits);
 
+  if (context->policy)
+    bus_policy_unref (context->policy);
   context->policy = bus_config_parser_steal_policy (parser);
   _dbus_assert (context->policy != NULL);