-
Notifications
You must be signed in to change notification settings - Fork 116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Qt Audio plugin freeze/crash conditions #1473
Comments
I can't reproduce this, neither the freeze nor the crash. |
Current testbed is Fedora 41 beta (x86_64). Simplified test-case for the freeze is:
|
I don't know if this might be related, but with a Ubuntu VM and Qt 6 I could reproduce lagging/stuttering audio output when seeking intensively. Like when moving the time slider fast and a lot. On my main setup with Arch Linux it works fine though. This patch helps for this case. Can you please try it as well @mschwendt? diff --git a/src/qtaudio/qtaudio.cc b/src/qtaudio/qtaudio.cc
index ee7c0f002..7428adca8 100644
--- a/src/qtaudio/qtaudio.cc
+++ b/src/qtaudio/qtaudio.cc
@@ -92,7 +92,7 @@ const char * const QtAudioOutput::defaults[] = {
nullptr
};
-static const timespec fifty_ms = {0, 50000000};
+static const timespec ten_ms = {0, 10000000};
static pthread_mutex_t mutex = PTHREAD_MUTEX_INITIALIZER;
static pthread_cond_t cond = PTHREAD_COND_INITIALIZER;
@@ -248,7 +248,7 @@ void QtAudioOutput::period_wait ()
while (output_instance->bytesFree () == 0)
{
- timespec ts = calc_abs_time (fifty_ms);
+ timespec ts = calc_abs_time (ten_ms);
pthread_cond_timedwait (& cond, & mutex, & ts);
}
@@ -274,7 +274,7 @@ void QtAudioOutput::drain ()
while (output_instance->bytesFree () < output_instance->bufferSize ())
{
- timespec ts = calc_abs_time (fifty_ms);
+ timespec ts = calc_abs_time (ten_ms);
pthread_cond_timedwait (& cond, & mutex, & ts);
} |
Seeking is instant here. Can't break it in any way. I don't use the Qt output plugin normally, though. |
In two corner-case situations, the Qt 6 based "QtMultimedia Output" plugin either freezes or crashes Audacious 4.4.1.
Or with an alternative step 3:
QObject::killTimer: Timers cannot be stopped from another thread
QObject::~QObject: Timers cannot be stopped from another thread
Segmentation fault (core dumped)
The text was updated successfully, but these errors were encountered: