Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(460)

Unified Diff: net/spdy/spdy_framer.cc

Issue 1328563002: clang_tidy net/spdy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/spdy/spdy_frame_builder.cc ('k') | net/spdy/spdy_framer_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_framer.cc
diff --git a/net/spdy/spdy_framer.cc b/net/spdy/spdy_framer.cc
index e4cb7c257b7e84e7fcde290d4d98ab934ff90827..bd3ea653a1dc77c81b37a487d8b69d5ef1e135cd 100644
--- a/net/spdy/spdy_framer.cc
+++ b/net/spdy/spdy_framer.cc
@@ -2986,8 +2986,9 @@ static const int kCompressorWindowSizeInBits = 11;
static const int kCompressorMemLevel = 1;
z_stream* SpdyFramer::GetHeaderCompressor() {
- if (header_compressor_.get())
+ if (header_compressor_.get()) {
return header_compressor_.get(); // Already initialized.
+ }
header_compressor_.reset(new z_stream);
memset(header_compressor_.get(), 0, sizeof(z_stream));
@@ -3016,8 +3017,9 @@ z_stream* SpdyFramer::GetHeaderCompressor() {
}
z_stream* SpdyFramer::GetHeaderDecompressor() {
- if (header_decompressor_.get())
+ if (header_decompressor_.get()) {
return header_decompressor_.get(); // Already initialized.
+ }
header_decompressor_.reset(new z_stream);
memset(header_decompressor_.get(), 0, sizeof(z_stream));
@@ -3100,8 +3102,9 @@ bool SpdyFramer::IncrementallyDecompressControlFrameHeaderData(
rv = inflateSetDictionary(decomp,
reinterpret_cast<const Bytef*>(dictionary),
dictionary_size);
- if (rv == Z_OK)
+ if (rv == Z_OK) {
rv = inflate(decomp, Z_SYNC_FLUSH);
+ }
}
}
« no previous file with comments | « net/spdy/spdy_frame_builder.cc ('k') | net/spdy/spdy_framer_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698