move pause to only exist on Scheduler

This commit is contained in:
Floris Bruynooghe
2023-03-09 15:44:17 +01:00
committed by link2xt
parent 52fa58a3ce
commit 2c3b2b8c2d
3 changed files with 8 additions and 16 deletions

View File

@@ -87,7 +87,7 @@ pub async fn imex(
let cancel = context.alloc_ongoing().await?;
let res = {
let mut guard = context.pause_io().await;
let mut guard = context.scheduler.pause(context).await;
let res = imex_inner(context, what, path, passphrase)
.race(async {
cancel.recv().await.ok();