Skip to content

Commit

Permalink
fix: do not shadow frame function parameter in GenerateSubsamplesFrom…
Browse files Browse the repository at this point in the history
…VPxFrame
  • Loading branch information
cosmin committed Jul 14, 2023
1 parent aea2fc9 commit ed55d62
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packager/media/crypto/subsample_generator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -270,11 +270,11 @@ Status SubsampleGenerator::GenerateSubsamplesFromVPxFrame(
SubsampleOrganizer subsample_organizer(align_protected_data_, subsamples);

size_t total_size = 0;
for (const VPxFrameInfo& frame : vpx_frames) {
for (const VPxFrameInfo& vpx_frame : vpx_frames) {
subsample_organizer.AddSubsample(
frame.uncompressed_header_size,
frame.frame_size - frame.uncompressed_header_size);
total_size += frame.frame_size;
vpx_frame.uncompressed_header_size,
vpx_frame.frame_size - vpx_frame.uncompressed_header_size);
total_size += vpx_frame.frame_size;
}
// Add subsample for the superframe index if exists.
const bool is_superframe = vpx_frames.size() > 1;
Expand Down

0 comments on commit ed55d62

Please sign in to comment.