MediaSync: fix flush handling and deadlock
- clear pending video frames
- flush audio track
- reset clock
- restart audio track after flush
- don't hold lock during callback
Bug: 22234976
Change-Id: I681df950b67d7f9f77a9c5783279f1c8c91be856
diff --git a/media/jni/android_media_MediaSync.h b/media/jni/android_media_MediaSync.h
index 22c77c7..6f80885 100644
--- a/media/jni/android_media_MediaSync.h
+++ b/media/jni/android_media_MediaSync.h
@@ -49,6 +49,8 @@
status_t setVideoFrameRateHint(float rate);
float getVideoFrameRate();
+ void flush();
+
sp<const MediaClock> getMediaClock();
protected: