Bug 1138983 - RTSP not enabled in Lollipop. r=vchang
authorEthan Tseng <ettseng@mozilla.com>
Thu, 05 Mar 2015 13:34:08 +0800
changeset 261051 fcaa845b28e8f7dca8006ea3d7f2c01ab76e4de3
parent 261050 5aaadad026257db63613324d4a62c980b2a442c4
child 261052 9f1ed4568d8e87304fc7d76d80845a6973e99998
push id4718
push userraliiev@mozilla.com
push dateMon, 11 May 2015 18:39:53 +0000
treeherdermozilla-beta@c20c4ef55f08 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersvchang
bugs1138983
milestone39.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1138983 - RTSP not enabled in Lollipop. r=vchang
configure.in
netwerk/protocol/rtsp/rtsp/RTSPSource.cpp
--- a/configure.in
+++ b/configure.in
@@ -298,16 +298,17 @@ if test -n "$gonkdir" ; then
         MOZ_FMP4=
         MOZ_B2G_CAMERA=1
         MOZ_B2G_BT=1
         MOZ_B2G_BT_BLUEDROID=1
         if test -d "$gonkdir/system/bluetoothd"; then
             MOZ_B2G_BT_DAEMON=1
         fi
         MOZ_NFC=1
+        MOZ_RTSP=1
         ;;
     *)
         AC_MSG_ERROR([Unsupported platform version: $ANDROID_VERSION])
         ;;
     esac
     CPPFLAGS="-DANDROID $TARGET_C_INCLUDES -I$gonkdir/system -I$gonkdir/system/core/include -isystem $gonkdir/bionic -I$gonkdir/hardware/libhardware/include -I$gonkdir/external/valgrind/fxos-include $GONK_INCLUDES $CPPFLAGS"
     CFLAGS="-mandroid -fno-short-enums -fno-exceptions $CFLAGS"
     CXXFLAGS="-mandroid -fno-short-enums -fno-exceptions -Wno-psabi $CXXFLAGS $STLPORT_CPPFLAGS"
--- a/netwerk/protocol/rtsp/rtsp/RTSPSource.cpp
+++ b/netwerk/protocol/rtsp/rtsp/RTSPSource.cpp
@@ -503,17 +503,22 @@ void RTSPSource::onMessageReceived(const
         {
             size_t trackIndex;
             CHECK(msg->findSize("trackIndex", &trackIndex));
             CHECK_LT(trackIndex, mTracks.size());
 
             TrackInfo *info = &mTracks.editItemAt(trackIndex);
             sp<AnotherPacketSource> source = info->mSource;
             if (source != NULL) {
+#if ANDROID_VERSION >= 21
+                source->queueDiscontinuity(ATSParser::DISCONTINUITY_SEEK, NULL,
+                                           true /* discard */);
+#else
                 source->queueDiscontinuity(ATSParser::DISCONTINUITY_SEEK, NULL);
+#endif
             }
 
             break;
         }
 
         case RtspConnectionHandler::kWhatNormalPlayTimeMapping:
         {
             size_t trackIndex;