◐ Shell
clean mode source ↗

src: fix http2 typos · nodejs/node@e92b89a

@@ -521,7 +521,7 @@ void Http2Stream::EmitStatistics() {

521521

Http2StreamPerformanceEntry* entry =

522522

new Http2StreamPerformanceEntry(env(), id_, statistics_);

523523

env()->SetImmediate([](Environment* env, void* data) {

524-

// This takes ownership, the entr is destroyed at the end of this scope.

524+

// This takes ownership, the entry is destroyed at the end of this scope.

525525

std::unique_ptr<Http2StreamPerformanceEntry> entry {

526526

static_cast<Http2StreamPerformanceEntry*>(data) };

527527

if (!HasHttp2Observer(env))

@@ -1000,7 +1000,7 @@ int Http2Session::OnDataChunkReceived(nghttp2_session* handle,

10001000

// `buf.base == nullptr` is the default Http2StreamListener's way

10011001

// of saying that it wants a pointer to the raw original.

10021002

// Since it has access to the original socket buffer from which the data

1003-

// was read in the first place, it can use that to minizime ArrayBuffer

1003+

// was read in the first place, it can use that to minimize ArrayBuffer

10041004

// allocations.

10051005

if (LIKELY(buf.base == nullptr))

10061006

buf.base = reinterpret_cast<char*>(const_cast<uint8_t*>(data));

@@ -1340,7 +1340,7 @@ void Http2Session::OnStreamAfterWrite(WriteWrap* w, int status) {

13401340

}

1341134113421342

// If the underlying nghttp2_session struct has data pending in its outbound

1343-

// queue, MaybeScheduleWrite will schedule a SendPendingData() call to occcur

1343+

// queue, MaybeScheduleWrite will schedule a SendPendingData() call to occur

13441344

// on the next iteration of the Node.js event loop (using the SetImmediate

13451345

// queue), but only if a write has not already been scheduled.

13461346

void Http2Session::MaybeScheduleWrite() {

@@ -2182,7 +2182,7 @@ void Http2Session::RefreshSettings(const FunctionCallbackInfo<Value>& args) {

2182218221832183

// A TypedArray instance is shared between C++ and JS land to contain state

21842184

// information of the current Http2Session. This updates the values in the

2185-

// TypedRray so those can be read in JS land.

2185+

// TypedArray so those can be read in JS land.

21862186

void Http2Session::RefreshState(const FunctionCallbackInfo<Value>& args) {

21872187

Environment* env = Environment::GetCurrent(args);

21882188

Http2Session* session;

@@ -2515,7 +2515,7 @@ void Http2Session::AltSvc(int32_t id,

25152515

origin, origin_len, value, value_len), 0);

25162516

}

251725172518-

// Submits an AltSvc frame to the sent to the connected peer.

2518+

// Submits an AltSvc frame to be sent to the connected peer.

25192519

void Http2Session::AltSvc(const FunctionCallbackInfo<Value>& args) {

25202520

Environment* env = Environment::GetCurrent(args);

25212521

Http2Session* session;