MCPcopy Index your code
hub / github.com/nodejs/node / afterOpen

Function afterOpen

lib/internal/http2/core.js:2868–2886  ·  view source on GitHub ↗
(session, options, headers, streamOptions, err, fd)

Source from the content-addressed store, hash-verified

2866}
2867
2868function afterOpen(session, options, headers, streamOptions, err, fd) {
2869 const state = this[kState];
2870 const onError = options.onError;
2871 if (err) {
2872 if (onError)
2873 onError(err);
2874 else
2875 this.destroy(err);
2876 return;
2877 }
2878 if (this.destroyed || this.closed) {
2879 tryClose(fd);
2880 return;
2881 }
2882 state.fd = fd;
2883
2884 fs.fstat(fd,
2885 doSendFileFD.bind(this, session, options, fd, headers, streamOptions));
2886}
2887
2888class ServerHttp2Stream extends Http2Stream {
2889 constructor(session, handle, id, options, headers) {

Callers

nothing calls this directly

Calls 5

tryCloseFunction · 0.85
fstatMethod · 0.80
onErrorFunction · 0.50
destroyMethod · 0.45
bindMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…