| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 5833007 commit 86ed87b
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3144,7 +3144,7 @@ function connect(authority, options, listener) { | |||
| 3144 | 3144 | debug('Http2Session connect', options.createConnection); | |
| 3145 | 3145 | // Socket already has some buffered data - emulate receiving it | |
| 3146 | 3146 | // https://github.com/nodejs/node/issues/35475 | |
| 3147 | - if (typeof options.createConnection === 'function') { | ||
| 3147 | + if (socket && socket.readableLength) { | ||
| 3148 | 3148 | let buf; | |
| 3149 | 3149 | while ((buf = socket.read()) !== null) { | |
| 3150 | 3150 | debug(`Http2Session connect: injecting ${buf.length} already in buffer`); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments