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-next>] [day] [month] [year] [list]
Message-Id: <20210310091014.6407-1-lyl2019@mail.ustc.edu.cn>
Date:   Wed, 10 Mar 2021 01:10:14 -0800
From:   Lv Yunlong <lyl2019@...l.ustc.edu.cn>
To:     johan@...nel.org, elder@...nel.org, gregkh@...uxfoundation.org
Cc:     greybus-dev@...ts.linaro.org, linux-kernel@...r.kernel.org,
        Lv Yunlong <lyl2019@...l.ustc.edu.cn>
Subject: [PATCH] greybus/operation: Drop reference when message has been set

In gb_operation_response_send, get an extra reference
before gb_message_send() with this comment "/* Reference will
be dropped when message has been sent. */". Therefore, we
should drop the got reference not only in the error branch,
but also in the complete branch.

Signed-off-by: Lv Yunlong <lyl2019@...l.ustc.edu.cn>
---
 drivers/greybus/operation.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/greybus/operation.c b/drivers/greybus/operation.c
index 296f0b93d171..500b3fe53a04 100644
--- a/drivers/greybus/operation.c
+++ b/drivers/greybus/operation.c
@@ -855,7 +855,7 @@ static int gb_operation_response_send(struct gb_operation *operation,
 	if (ret)
 		goto err_put_active;
 
-	/*Drop reference after message send successfully. */
+	/*Drop reference after message send completes. */
 	gb_operation_put_active(operation);
 	gb_operation_put(operation);
 
-- 
2.25.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ