mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2024-11-27 05:51:01 +00:00
proxy: fix items mistakenly discarded
When emptying the pending queue, we need to break as soon as as we failed to push an item to the data queue, otherwise only the last failed item is pushed back to the front of the pending queue, and all the previously failed items in the loop get discarded
This commit is contained in:
parent
bcae2423f5
commit
49f73fbf61
1 changed files with 2 additions and 0 deletions
|
@ -524,6 +524,7 @@ impl ProxySink {
|
|||
while let Some(item) = pending_queue.items.pop_front() {
|
||||
if let Err(item) = dataqueue.push(item).await {
|
||||
failed_item = Some(item);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -587,6 +588,7 @@ impl ProxySink {
|
|||
while let Some(item) = pending_queue.items.pop_front() {
|
||||
if let Err(item) = dataqueue.push(item).await {
|
||||
failed_item = Some(item);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue