[FFmpeg-devel] parse_date using localtime etc.
Reimar Döffinger
Reimar.Doeffinger
Fri Feb 6 11:11:05 CET 2009
Hello,
as it came out during a recent discussion, parse_date uses the
non-thread-safe functions localtime and gmtime.
This is not much of an issue currently, since libav* does not use that
code path.
However I still have a bad feeling about it, since libav* functions are
expected to not have global side-effects and to be thread safe.
The question is what to do about it.
I think at the very least there should be a big fat warning in the doxy
comments, that when duration is == 0, that function uses localtime etc.
and thus is not thread safe.
Which means it can only be used in a threaded application with extreme
care, and libav* may _never_ use it with duration == 0.
Greetings,
Reimar D?ffinger
More information about the ffmpeg-devel
mailing list