diff options
author | Santhosh Behara <santhoshbehara@codeaurora.org> | 2015-01-20 19:30:58 +0530 |
---|---|---|
committer | Steve Kondik <steve@cyngn.com> | 2015-01-31 23:27:18 -0800 |
commit | 97e2c881777b708d0115471b7e5a5248af157cd2 (patch) | |
tree | ee011770d3ff63b4a947ed4d359d4100b6e8a64a | |
parent | e77455d820baaf30697c03815608270236928427 (diff) | |
download | frameworks_av-97e2c881777b708d0115471b7e5a5248af157cd2.tar.gz frameworks_av-97e2c881777b708d0115471b7e5a5248af157cd2.tar.bz2 frameworks_av-97e2c881777b708d0115471b7e5a5248af157cd2.zip |
RTSP: Add NULL check before accessing mHandler
When there are no packets received from n/w, the RTSP client
sends a Teardown message to the server and mHandler becomes NULL.
Added NULL check before accessing mHandler object.
CRs-Fixed: 785307
Change-Id: Ia429d658a4683640e2d03f0ebe42ae46c9ce3b52
-rw-r--r-- | media/libmediaplayerservice/nuplayer/RTSPSource.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/media/libmediaplayerservice/nuplayer/RTSPSource.cpp b/media/libmediaplayerservice/nuplayer/RTSPSource.cpp index 7ddfd76f16..7bf530ce9f 100644 --- a/media/libmediaplayerservice/nuplayer/RTSPSource.cpp +++ b/media/libmediaplayerservice/nuplayer/RTSPSource.cpp @@ -134,7 +134,9 @@ void NuPlayer::RTSPSource::pause() { // Check if EOS or ERROR is received if (source != NULL && source->isFinished(mediaDurationUs)) { ALOGI("Nearing EOS...No Pause is issued"); - mHandler->setAUTimeoutCheck(false); + if (mHandler != NULL) { + mHandler->setAUTimeoutCheck(false); + } return; } } |