lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200702002635.8169-4-matt.bennett@alliedtelesis.co.nz>
Date:   Thu,  2 Jul 2020 12:26:33 +1200
From:   Matt Bennett <matt.bennett@...iedtelesis.co.nz>
To:     netdev@...r.kernel.org
Cc:     zbr@...emap.net, ebiederm@...ssion.com,
        linux-kernel@...r.kernel.org,
        Matt Bennett <matt.bennett@...iedtelesis.co.nz>
Subject: [PATCH 3/5] connector: Ensure callback entry is released

Currently the entry itself appears to be being leaked.

Signed-off-by: Matt Bennett <matt.bennett@...iedtelesis.co.nz>
---
 drivers/connector/cn_queue.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/connector/cn_queue.c b/drivers/connector/cn_queue.c
index 49295052ba8b..a82ceeb37f26 100644
--- a/drivers/connector/cn_queue.c
+++ b/drivers/connector/cn_queue.c
@@ -132,8 +132,10 @@ void cn_queue_free_dev(struct cn_queue_dev *dev)
 	struct cn_callback_entry *cbq, *n;
 
 	spin_lock_bh(&dev->queue_lock);
-	list_for_each_entry_safe(cbq, n, &dev->queue_list, callback_entry)
+	list_for_each_entry_safe(cbq, n, &dev->queue_list, callback_entry) {
 		list_del(&cbq->callback_entry);
+		cn_queue_release_callback(cbq);
+	}
 	spin_unlock_bh(&dev->queue_lock);
 
 	while (atomic_read(&dev->refcnt)) {
-- 
2.27.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ