Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
7d6b04dd by Steve Lhomme at 2026-01-09T12:35:34+00:00
demux: libmp4: don't compute ms if it's forced to 0
For example if i_scale is 0, which results in a division by zero.
Fixes #29522 and #29303
- - - - -
1 changed file:
- modules/demux/mp4/libmp4.c
Changes:
=====================================
modules/demux/mp4/libmp4.c
=====================================
@@ -61,7 +61,8 @@ static char * MP4_Time2Str( stime_t i_duration, uint32_t
i_scale )
uint64_t ms;
if ( i_scale == 0 || ckd_mul( &ms, 1000, i_duration ) )
ms = 0;
- ms = (ms / i_scale) % 1000;
+ else
+ ms = (ms / i_scale) % 1000;
char *out;
if( asprintf( &out, "%u:%.2u:%.2u:%.3" PRIu64, h, m, s, ms ) < 0 )
View it on GitLab:
https://code.videolan.org/videolan/vlc/-/commit/7d6b04dd6dd5e46d4156044b6586e7a6527bddc0
--
View it on GitLab:
https://code.videolan.org/videolan/vlc/-/commit/7d6b04dd6dd5e46d4156044b6586e7a6527bddc0
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance_______________________________________________
vlc-commits mailing list
[email protected]
https://mailman.videolan.org/listinfo/vlc-commits