aboutsummaryrefslogtreecommitdiff
path: root/ext/wasm/tests/opfs/concurrency/worker.js
diff options
context:
space:
mode:
authordrh <>2022-11-24 01:41:44 +0000
committerdrh <>2022-11-24 01:41:44 +0000
commit4b1555a9fc77dfaca1ee3eab38a2ba424a9d4ad9 (patch)
tree9df8ca7ad4fb96cfb9b0c97497b10152cb758cae /ext/wasm/tests/opfs/concurrency/worker.js
parent9b80cb5f39af66075762057df127ffbbb2c6ef2a (diff)
parentf1ce4f40c7a01fd272662ab42d24b1f3ba747069 (diff)
downloadsqlite-4b1555a9fc77dfaca1ee3eab38a2ba424a9d4ad9.tar.gz
sqlite-4b1555a9fc77dfaca1ee3eab38a2ba424a9d4ad9.zip
Merge the latest trunk changes into the agg-with-indexed-expr branch to
simplify diffs. FossilOrigin-Name: 38c3d3f1ed0fd2bb62aa8a7e5a27f2b247123e094e2fdb0a2475d788c3dfbc04
Diffstat (limited to 'ext/wasm/tests/opfs/concurrency/worker.js')
-rw-r--r--ext/wasm/tests/opfs/concurrency/worker.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/ext/wasm/tests/opfs/concurrency/worker.js b/ext/wasm/tests/opfs/concurrency/worker.js
index c315508e0..19b0a068e 100644
--- a/ext/wasm/tests/opfs/concurrency/worker.js
+++ b/ext/wasm/tests/opfs/concurrency/worker.js
@@ -70,11 +70,12 @@ self.sqlite3InitModule().then(async function(sqlite3){
}
};
if(1){/*use setInterval()*/
- interval.handle = setInterval(async ()=>{
+ setTimeout(async function timer(){
await doWork();
if(interval.error || maxIterations === interval.count){
- clearInterval(interval.handle);
finish();
+ }else{
+ setTimeout(timer, interval.delay);
}
}, interval.delay);
}else{