Update Ap4TfraAtom.cpp

Update Ap4TfraAtom.cpp to fix Division-by-zero in Ap4TfraAtom.cpp:153
This commit is contained in:
Sisyphus-wang
2025-07-18 18:57:09 +08:00
committed by GitHub
parent 0d86d53a15
commit a54a1eb9ab

View File

@@ -150,7 +150,7 @@ AP4_TfraAtom::AP4_TfraAtom(AP4_UI32 size,
}
// Check that it all fits
if (((size - (AP4_FULL_ATOM_HEADER_SIZE+4+4+4)) / entry_count) < entry_size) {
if (entry_count<=0 ((size - (AP4_FULL_ATOM_HEADER_SIZE+4+4+4)) / entry_count) < entry_size) {
return;
}