On Tue, 2012-11-20 at 12:45 +0200, Tanu Kaskinen wrote:
> On Mon, 2012-11-19 at 21:45 +0100, Brendan Jones wrote:
> > I'm seeing this in virtual box under KDE (also Fedora 18 / pulseaudio 2.1).
> > 
> > On my real desktop, if I configure qjackctl to autostart on logon and in 
> > turn autostart jack I do not see the problem.
> > 
> > If I stop jack and resume normal desktop use and restart jack after a 
> > time, the issue does occur.
> > 
> > pulseaudio --kill; pulseaudio --start always fixes the issue.
> > 
> > Is there something I can look out for in the logs, or something I can 
> > try via pacmd while it is happening to aid in debugging this issue?
> > 
> > We are very close to the release date of the Fedora Audio spin and 
> > really want to have jack and pulse coexist directly from the install 
> > media but this issue is holding us back.
> > 
> > Let me know if there is anyway I can help
> 
> I can reproduce some weird behavior which I've been investigating, but
> right now there's a bluetooth bug that is at a higher priority. I think
> I can finish that today, though, so I can continue with this device
> reservation stuff right after that.
> 
> I don't think I need more debug information right now - let's see if
> fixing the bugs that I'm seeing also fixes your issues.

I've attached a patch that fixes the bug that I've been investigating.
The fix ended up being very simple, but I think it's quite unlikely that
it will fix your problem. If you could try the patch, that would be
great. In the mean time, I'll try to reproduce the bug that you're
seeing.

-- 
Tanu
>From 179e96dd5bb49dfb14da1db59debe79231f5101d Mon Sep 17 00:00:00 2001
From: Tanu Kaskinen <ta...@iki.fi>
Date: Tue, 20 Nov 2012 18:26:42 +0200
Subject: [PATCH] reserve: Call change_cb() only if there actually was a
 change.

---
 src/modules/reserve-monitor.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/modules/reserve-monitor.c b/src/modules/reserve-monitor.c
index ab453e6..4097a6f 100644
--- a/src/modules/reserve-monitor.c
+++ b/src/modules/reserve-monitor.c
@@ -85,6 +85,8 @@ static DBusHandlerResult filter_handler(
 			goto invalid;
 
 		if (strcmp(name, m->service_name) == 0) {
+			unsigned old_busy = m->busy;
+
 			m->busy = !!(new && *new);
 
 			/* If we ourselves own the device, then don't consider this 'busy' */
@@ -96,7 +98,7 @@ static DBusHandlerResult filter_handler(
 						m->busy = FALSE;
 			}
 
-			if (m->change_cb) {
+			if (m->busy != old_busy && m->change_cb) {
 				m->ref++;
 				m->change_cb(m);
 				rm_release(m);
-- 
1.7.10.4

_______________________________________________
pulseaudio-discuss mailing list
pulseaudio-discuss@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss

Reply via email to