Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrançois Laignel <fengalin@free.fr>2020-10-19 19:10:06 +0300
committerFrançois Laignel <fengalin@free.fr>2020-10-21 00:45:01 +0300
commit4eacce80a58206a61da7b15985e9250fdd34aa23 (patch)
treef3f1b7e97a2da93976e092b975f7474df9279b1d /generic/threadshare/src
parent7c3e69bb4aba6e3a5da95e3c610b85d5b629fb72 (diff)
threadshare: runtime: simplify a function thanks to clippy
Diffstat (limited to 'generic/threadshare/src')
-rw-r--r--generic/threadshare/src/runtime/executor.rs14
1 files changed, 6 insertions, 8 deletions
diff --git a/generic/threadshare/src/runtime/executor.rs b/generic/threadshare/src/runtime/executor.rs
index 2b0c6f361..b8c2e01f6 100644
--- a/generic/threadshare/src/runtime/executor.rs
+++ b/generic/threadshare/src/runtime/executor.rs
@@ -632,15 +632,13 @@ impl Context {
}
}
- pub fn drain_sub_tasks() -> impl Future<Output = SubTaskOutput> + Send + 'static {
- async {
- let (ctx, task_id) = match Context::current_task() {
- Some(task) => task,
- None => return Ok(()),
- };
+ pub async fn drain_sub_tasks() -> SubTaskOutput {
+ let (ctx, task_id) = match Context::current_task() {
+ Some(task) => task,
+ None => return Ok(()),
+ };
- ctx.drain_sub_tasks_internal(task_id).await
- }
+ ctx.drain_sub_tasks_internal(task_id).await
}
fn drain_sub_tasks_internal(