History

avformat/mxfdec: fix variable shadowing

Marvin Scholz committed 2 years ago

Commit f5107e71 parent dd002f11 file · +9 −9Browse files

Unified · Split

libavformat/mxfdec.c+9−9
@@ -871,16 +871,16 @@ static int mxf_read_partition_pack(void *arg, AVIOContext *pb, int tag, int size · 870 unmodified lines
871871 * 2011_DCPTEST_24FPS.V.mxf - two ECs, OP1a
872872 * abcdefghiv016f56415e.mxf - zero ECs, OPAtom, output by Avid AirSpeed */
873873 if (nb_essence_containers != 1) {
874− MXFOP op = nb_essence_containers ? OP1a : OPAtom;
874+ MXFOP mxfop = nb_essence_containers ? OP1a : OPAtom;
875875
876876 /* only nag once */
877877 if (!mxf->op)
878878 av_log(mxf->fc, AV_LOG_WARNING,
879879 "\"OPAtom\" with %"PRIu32" ECs - assuming %s\n",
880880 nb_essence_containers,
881− op == OP1a ? "OP1a" : "OPAtom");
881+ mxfop == OP1a ? "OP1a" : "OPAtom");
882882
883− mxf->op = op;
883+ mxf->op = mxfop;
884884 } else
885885 mxf->op = OPAtom;
886886 } else {
@@ -2574,7 +2574,7 @@ static int parse_mca_labels(MXFContext *mxf, MXFTrack *source_track, MXFDescript · 1687 unmodified lines
25742574 }
25752575
25762576 if (language && !ambigous_language) {
2577− int ret = set_language(mxf->fc, language, &st->metadata);
2577+ ret = set_language(mxf->fc, language, &st->metadata);
25782578 if (ret < 0)
25792579 return ret;
25802580 }
@@ -2601,10 +2601,10 @@ static int parse_mca_labels(MXFContext *mxf, MXFTrack *source_track, MXFDescript · 20 unmodified lines
26012601 static int mxf_parse_structural_metadata(MXFContext *mxf)
26022602 {
26032603 MXFPackage *material_package = NULL;
2604− int i, j, k, ret;
2604+ int k, ret;
26052605
26062606 /* TODO: handle multiple material packages (OP3x) */
2607− for (i = 0; i < mxf->packages_count; i++) {
2607+ for (int i = 0; i < mxf->packages_count; i++) {
26082608 material_package = mxf_resolve_strong_ref(mxf, &mxf->packages_refs[i], MaterialPackage);
26092609 if (material_package) break;
26102610 }
@@ -2618,7 +2618,7 @@ static int mxf_parse_structural_metadata(MXFContext *mxf) · 7 unmodified lines
26182618 av_dict_set(&mxf->fc->metadata, "material_package_name", material_package->name, 0);
26192619 mxf_parse_package_comments(mxf, &mxf->fc->metadata, material_package);
26202620
2621− for (i = 0; i < material_package->tracks_count; i++) {
2621+ for (int i = 0; i < material_package->tracks_count; i++) {
26222622 MXFPackage *source_package = NULL;
26232623 MXFTrack *material_track = NULL;
26242624 MXFTrack *source_track = NULL;
@@ -2653,7 +2653,7 @@ static int mxf_parse_structural_metadata(MXFContext *mxf) · 28 unmodified lines
26532653 continue;
26542654 }
26552655
2656− for (j = 0; j < material_track->sequence->structural_components_count; j++) {
2656+ for (int j = 0; j < material_track->sequence->structural_components_count; j++) {
26572657 component = mxf_resolve_strong_ref(mxf, &material_track->sequence->structural_components_refs[j], TimecodeComponent);
26582658 if (!component)
26592659 continue;
@@ -2671,7 +2671,7 @@ static int mxf_parse_structural_metadata(MXFContext *mxf) · 11 unmodified lines
26712671 av_log(mxf->fc, AV_LOG_WARNING, "material track %d: has %d components\n",
26722672 material_track->track_id, material_track->sequence->structural_components_count);
26732673
2674− for (j = 0; j < material_track->sequence->structural_components_count; j++) {
2674+ for (int j = 0; j < material_track->sequence->structural_components_count; j++) {
26752675 component = mxf_resolve_sourceclip(mxf, &material_track->sequence->structural_components_refs[j]);
26762676 if (!component)
26772677 continue;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t