projects
/
pulseview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f896568
)
SigSession: Fixed std::thread joining
author
Joel Holdsworth
<joel@airwebreathe.org.uk>
Thu, 29 May 2014 22:22:52 +0000
(23:22 +0100)
committer
Joel Holdsworth
<joel@airwebreathe.org.uk>
Thu, 5 Jun 2014 19:49:19 +0000
(20:49 +0100)
pv/sigsession.cpp
patch
|
blob
|
history
diff --git
a/pv/sigsession.cpp
b/pv/sigsession.cpp
index 87b561eb11ccc8a09aea5db2b1f2f652810a5344..e42ba2cbdc3f997d73f67e0b855f6affb4f55e0b 100644
(file)
--- a/
pv/sigsession.cpp
+++ b/
pv/sigsession.cpp
@@
-77,11
+77,9
@@
SigSession::~SigSession()
{
using pv::device::Device;
+ // Stop and join to the thread
stop_capture();
- if (_sampling_thread.joinable())
- _sampling_thread.join();
-
_dev_inst->release();
// TODO: This should not be necessary
@@
-195,10
+193,8
@@
void SigSession::start_capture(function<void (const QString)> error_handler)
void SigSession::stop_capture()
{
- if (get_capture_state() == Stopped)
- return;
-
- sr_session_stop();
+ if (get_capture_state() != Stopped)
+ sr_session_stop();
// Check that sampling stopped
if (_sampling_thread.joinable())