nghttpx: Simplify

We only change req_.upgrade_request once, so just using else is
suffice.
This commit is contained in:
Tatsuhiro Tsujikawa 2016-01-15 00:22:11 +09:00
parent f8472f4709
commit 3c7038dfe1
1 changed files with 1 additions and 3 deletions

View File

@ -677,9 +677,7 @@ void Downstream::inspect_http2_request() {
void Downstream::inspect_http1_request() {
if (req_.method == HTTP_CONNECT) {
req_.upgrade_request = true;
}
if (!req_.upgrade_request) {
} else {
auto upgrade = req_.fs.header(http2::HD_UPGRADE);
if (upgrade) {
const auto &val = upgrade->value;