Skip to content
Permalink
Browse files Browse the repository at this point in the history
fixed #1705
  • Loading branch information
jeanlf committed Mar 12, 2021
1 parent a3862a8 commit 2da2f68
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/isomedia/stbl_read.c
Expand Up @@ -419,11 +419,13 @@ GF_Err stbl_GetSampleInfos(GF_SampleTableBox *stbl, u32 sampleNumber, u64 *offse
if ( stbl->ChunkOffset->type == GF_ISOM_BOX_TYPE_STCO) {
stco = (GF_ChunkOffsetBox *)stbl->ChunkOffset;
if (!stco->offsets) return GF_ISOM_INVALID_FILE;
if (stco->nb_entries < sampleNumber) return GF_ISOM_INVALID_FILE;

(*offset) = (u64) stco->offsets[sampleNumber - 1];
} else {
co64 = (GF_ChunkLargeOffsetBox *)stbl->ChunkOffset;
if (!co64->offsets) return GF_ISOM_INVALID_FILE;
if (co64->nb_entries < sampleNumber) return GF_ISOM_INVALID_FILE;

(*offset) = co64->offsets[sampleNumber - 1];
}
Expand Down

0 comments on commit 2da2f68

Please sign in to comment.