summaryrefslogtreecommitdiff
path: root/ext/http/00_serve.js
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2023-08-03 22:36:32 +0200
committerGitHub <noreply@github.com>2023-08-03 20:36:32 +0000
commit433ecc9047c1701a6b384fc94593c1f41f9f6bf6 (patch)
tree1e26e0b91a9f247678e347b133773ec1ad0b913a /ext/http/00_serve.js
parent7f8bf2537db0ae596a2c1baabd4011a190666ca6 (diff)
refactor: rewrite http_next ops to use op2 macro (#19934)
Ref #19915 --------- Co-authored-by: Matt Mastracci <matthew@mastracci.com>
Diffstat (limited to 'ext/http/00_serve.js')
-rw-r--r--ext/http/00_serve.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/http/00_serve.js b/ext/http/00_serve.js
index b51dfee07..af4353e0e 100644
--- a/ext/http/00_serve.js
+++ b/ext/http/00_serve.js
@@ -726,7 +726,7 @@ function serveHttpOn(context, callback) {
try {
// Attempt to pull as many requests out of the queue as possible before awaiting. This API is
// a synchronous, non-blocking API that returns u32::MAX if anything goes wrong.
- while ((req = op_http_try_wait(rid)) !== 0xffffffff) {
+ while ((req = op_http_try_wait(rid)) !== -1) {
PromisePrototypeCatch(callback(req), promiseErrorHandler);
}
currentPromise = op_http_wait(rid);
@@ -741,7 +741,7 @@ function serveHttpOn(context, callback) {
}
throw new Deno.errors.Http(error);
}
- if (req === 0xffffffff) {
+ if (req === -1) {
break;
}
PromisePrototypeCatch(callback(req), promiseErrorHandler);