mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-02-03 09:44:01 -05:00
DATV demod: use non blocking read in ldpctool to fix issue in PR #1345
This commit is contained in:
parent
1057bc2882
commit
2612d6793e
@ -3827,10 +3827,16 @@ struct s2_fecdec_helper : runnable
|
||||
const s2_pls *pls = &job->pls;
|
||||
int iosize = (pls->framebits() / 8) * sizeof(ldpc_buf[0]);
|
||||
|
||||
// Blocking read - do we need to return faster?
|
||||
// If so, call m_worker->dataAvailable()
|
||||
QByteArray data = job->h->m_worker->data();
|
||||
memcpy(ldpc_buf, data.data(), data.size());
|
||||
// Non blocking read - will do the next time if no adata is available
|
||||
if (job->h->m_worker->dataAvailable())
|
||||
{
|
||||
QByteArray data = job->h->m_worker->data();
|
||||
memcpy(ldpc_buf, data.data(), data.size());
|
||||
}
|
||||
else
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
--job->h->b_out;
|
||||
// Decode BCH.
|
||||
|
Loading…
Reference in New Issue
Block a user