mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-03-17 20:17:55 +02:00
mxf_timestamp_to_str: dont leave uninitilaized fields in time.
Fixes CID1005318 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
63090842df
commit
578d9cf7cc
@ -1660,7 +1660,7 @@ static int mxf_uid_to_str(UID uid, char **str)
|
|||||||
|
|
||||||
static int mxf_timestamp_to_str(uint64_t timestamp, char **str)
|
static int mxf_timestamp_to_str(uint64_t timestamp, char **str)
|
||||||
{
|
{
|
||||||
struct tm time;
|
struct tm time = {0};
|
||||||
time.tm_year = (timestamp >> 48) - 1900;
|
time.tm_year = (timestamp >> 48) - 1900;
|
||||||
time.tm_mon = (timestamp >> 40 & 0xFF) - 1;
|
time.tm_mon = (timestamp >> 40 & 0xFF) - 1;
|
||||||
time.tm_mday = (timestamp >> 32 & 0xFF);
|
time.tm_mday = (timestamp >> 32 & 0xFF);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user