summaryrefslogtreecommitdiff
path: root/test/parallel/test-http2-max-session-memory-leak.js
AgeCommit message (Collapse)Author
2019-05-29http2: fix tracking received data for maxSessionMemoryAnna Henningsen
Track received data correctly. Specifically, for the buffer that is used for receiving data, we previously would try to increment the current memory usage by its length, and later decrement it by that, but in the meantime the buffer had been turned over to V8 and its length reset to zero. This gave the impression that more and more memory was consumed by the HTTP/2 session when it was in fact not. Fixes: https://github.com/nodejs/node/issues/27416 Refs: https://github.com/nodejs/node/pull/26207 PR-URL: https://github.com/nodejs/node/pull/27914 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>