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

Function startFilePipe

lib/internal/http2/core.js:2747–2760  ·  view source on GitHub ↗
(self, fd, offset, length)

Source from the content-addressed store, hash-verified

2745}
2746
2747function startFilePipe(self, fd, offset, length) {
2748 const handle = new FileHandle(fd, offset, length);
2749 handle.onread = onPipedFileHandleRead;
2750 handle.stream = self;
2751
2752 const pipe = new StreamPipe(handle, self[kHandle]);
2753 pipe.onunpipe = onFileUnpipe;
2754 pipe.start();
2755
2756 // Exact length of the file doesn't matter here, since the
2757 // stream is closing anyway - just use 1 to signify that
2758 // a write does exist
2759 trackWriteState(self, 1);
2760}
2761
2762function doSendFD(session, options, fd, headers, streamOptions, err, stat) {
2763 if (err) {

Callers

nothing calls this directly

Calls 2

trackWriteStateFunction · 0.85
startMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…