Commit 814fce4b authored by gejun's avatar gejun

Rename EndRemoteStream to OnEndStream

parent 189098f9
......@@ -646,12 +646,12 @@ H2ParseResult H2StreamContext::OnHeaders(
return MakeH2Error(H2_PROTOCOL_ERROR);
}
if (frame_head.flags & H2_FLAGS_END_STREAM) {
return EndRemoteStream();
return OnEndStream();
}
return MakeH2Message(NULL);
} else {
if (frame_head.flags & H2_FLAGS_END_STREAM) {
// Delay calling EndRemoteStream() in OnContinuation()
// Delay calling OnEndStream() in OnContinuation()
_stream_ended = true;
}
return MakeH2Message(NULL);
......@@ -696,7 +696,7 @@ H2ParseResult H2StreamContext::OnContinuation(
return MakeH2Error(H2_PROTOCOL_ERROR);
}
if (_stream_ended) {
return EndRemoteStream();
return OnEndStream();
}
}
return MakeH2Message(NULL);
......@@ -774,7 +774,7 @@ H2ParseResult H2StreamContext::OnData(
}
}
if (frame_head.flags & H2_FLAGS_END_STREAM) {
return EndRemoteStream();
return OnEndStream();
}
return MakeH2Message(NULL);
}
......@@ -823,7 +823,7 @@ H2ParseResult H2StreamContext::OnResetStream(
}
}
H2ParseResult H2StreamContext::EndRemoteStream() {
H2ParseResult H2StreamContext::OnEndStream() {
#if defined(BRPC_H2_STREAM_STATE)
if (state() == H2_STREAM_OPEN) {
SetState(H2_STREAM_HALF_CLOSED_REMOTE);
......
......@@ -235,7 +235,7 @@ public:
// does not need to complete.
// Returns 0 on success, -1 otherwise.
int ConsumeHeaders(butil::IOBufBytesIterator& it);
H2ParseResult EndRemoteStream();
H2ParseResult OnEndStream();
H2ParseResult OnData(butil::IOBufBytesIterator&, const H2FrameHead&,
uint32_t frag_size, uint8_t pad_length);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment