Files
ports/science/pulseview/files/patch-pv_data_decodesignal.cpp
T
Andriy Gapon d0cf6f3444 science/pulseview: fix crash on startup when libcxx has asserts enabled
The program's code unlocks a mutex that it never locked.
When libcxx is built with debug (e.g., on stable branches) there is a
crash on an assert that pthread_mutex_unlock succeeds.

This change adds a patch for the problem.

PR:		282727
Approved by:	uzsolt
2025-02-21 08:06:49 +02:00

16 lines
508 B
C++

--- pv/data/decodesignal.cpp.orig 2020-03-31 23:41:18.000000000 +0300
+++ pv/data/decodesignal.cpp 2024-11-08 15:04:00.844432000 +0200
@@ -251,11 +251,8 @@
void DecodeSignal::resume_decode()
{
- // Manual unlocking is done before notifying, to avoid waking up the
- // waiting thread only to block again (see notify_one for details)
- decode_pause_mutex_.unlock();
- decode_pause_cond_.notify_one();
decode_paused_ = false;
+ decode_pause_cond_.notify_one();
}
bool DecodeSignal::is_paused() const