aboutsummaryrefslogtreecommitdiffstats
path: root/extension
diff options
context:
space:
mode:
authorOmar Rizwan <omar@omar.website>2021-01-04 03:35:17 -0800
committerGitHub <noreply@github.com>2021-01-04 03:35:17 -0800
commit6e829c1f17aca37810105d5f4408ff9466d5d7de (patch)
treec7eb65c466ba3619a6396190f18731029f888c4c /extension
parent11834af93650645b902d3c1974f26d85f775c1f8 (diff)
parent57331e2092ec8d7cd5ebb4b8b6ec2bdf2d2b5661 (diff)
Merge pull request #29 from huglovefan/master
multi-threaded tabfs.c
Diffstat (limited to 'extension')
-rw-r--r--extension/background.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/extension/background.js b/extension/background.js
index 7851b22..179a2b8 100644
--- a/extension/background.js
+++ b/extension/background.js
@@ -650,7 +650,7 @@ async function onMessage(req) {
// timeout is very useful because some operations just hang
// (like trying to take a screenshot, until the tab is focused)
didTimeout = true; console.error('timeout');
- port.postMessage({ op: req.op, error: unix.ETIMEDOUT });
+ port.postMessage({ id: req.id, op: req.op, error: unix.ETIMEDOUT });
}, 1000);
/* console.time(req.op + ':' + req.path);*/
@@ -672,6 +672,7 @@ async function onMessage(req) {
clearTimeout(timeout);
console.log('resp', response);
+ response.id = req.id;
port.postMessage(response);
}
};