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

Unified Diff: media/filters/vp8_parser.cc

Issue 1992663002: Vp8Parser: Zero-initialize segment feature data when required (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/vp8_parser.cc
diff --git a/media/filters/vp8_parser.cc b/media/filters/vp8_parser.cc
index 008847880b9dafc486ab784f203ee4207c637d70..54b0c4294ea04d0ae1561f35aa443cb59f290ef8 100644
--- a/media/filters/vp8_parser.cc
+++ b/media/filters/vp8_parser.cc
@@ -242,6 +242,8 @@ bool Vp8Parser::ParseSegmentationHeader(bool keyframe) {
BD_READ_BOOL_OR_RETURN(&quantizer_update);
if (quantizer_update)
BD_READ_SIGNED_OR_RETURN(7, &shdr->quantizer_update_value[i]);
+ else
+ shdr->quantizer_update_value[i] = 0;
}
for (size_t i = 0; i < kMaxMBSegments; ++i) {
@@ -249,6 +251,8 @@ bool Vp8Parser::ParseSegmentationHeader(bool keyframe) {
BD_READ_BOOL_OR_RETURN(&loop_filter_update);
if (loop_filter_update)
BD_READ_SIGNED_OR_RETURN(6, &shdr->lf_update_value[i]);
+ else
+ shdr->lf_update_value[i] = 0;
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698