Fix issues crashing with Fatal signal when calling getFormat
when playing multimedia file, GenericSource::getTrackInfo run in the
NuPlayerDriver thread, and GenericSource::getFormatMeta run in the
Generic thread. they would access the critical resource which is
mMetaData in IMediaSource. There is no lock to protect mMetaData.
Occasionally, SIGSEGV occurs when mMetaData point to a new object.
Instead getting trackInfo in Generic thread.
Signed-off-by: qinzhichao <firstname.lastname@example.org>
2 files changed