linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Szymon Janc <szymon.janc@codecoup.pl>
To: linux-bluetooth@vger.kernel.org
Cc: Szymon Janc <szymon.janc@codecoup.pl>
Subject: [PATCH] monitor: Fix crash when using RTT backend
Date: Fri, 24 Jun 2022 10:25:41 +0200	[thread overview]
Message-ID: <20220624082541.51687-1-szymon.janc@codecoup.pl> (raw)

This fix regression introduced by "monitor: Fix memory leaks".
J-Link shared library is in use if jlink_init() returns 0 and thus
handle shall not be closed.
---
 monitor/jlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/monitor/jlink.c b/monitor/jlink.c
index f1d8ce660..f9d4037f4 100644
--- a/monitor/jlink.c
+++ b/monitor/jlink.c
@@ -112,7 +112,7 @@ int jlink_init(void)
 		return -EIO;
 	}
 
-	dlclose(so);
+	/* don't dlclose(so) here cause symbols from it are in use now */
 	return 0;
 }
 
-- 
2.36.1


             reply	other threads:[~2022-06-24  8:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-24  8:25 Szymon Janc [this message]
2022-06-24  9:29 ` monitor: Fix crash when using RTT backend bluez.test.bot
2022-06-27  8:25   ` Szymon Janc
2022-06-27  8:30 ` [PATCH] " patchwork-bot+bluetooth

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220624082541.51687-1-szymon.janc@codecoup.pl \
    --to=szymon.janc@codecoup.pl \
    --cc=linux-bluetooth@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).