mirror of
https://github.com/nodejs/node.git
synced 2025-08-16 06:08:50 +02:00
http: use objects with null prototype in Agent
Fixes: https://github.com/nodejs/node/issues/36364 PR-URL: https://github.com/nodejs/node/pull/36409 Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
parent
c6c8337402
commit
2ef9a76ece
9 changed files with 33 additions and 19 deletions
|
@ -70,8 +70,8 @@ server.listen(0, common.mustCall(() => {
|
|||
req.on('connect', common.mustCall((res, socket, firstBodyChunk) => {
|
||||
// Make sure this request got removed from the pool.
|
||||
const name = `localhost:${server.address().port}`;
|
||||
assert(!http.globalAgent.sockets.hasOwnProperty(name));
|
||||
assert(!http.globalAgent.requests.hasOwnProperty(name));
|
||||
assert(!(name in http.globalAgent.sockets));
|
||||
assert(!(name in http.globalAgent.requests));
|
||||
|
||||
// Make sure this socket has detached.
|
||||
assert(!socket.ondata);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue