am 3c78a1b5: Return a runtime error instead of asserting if the AACDecoder is passed an unsupported config.
Merge commit '3c78a1b58957e31d2991fb6a609abecbb1987b3b' into froyo-plus-aosp * commit '3c78a1b58957e31d2991fb6a609abecbb1987b3b': Return a runtime error instead of asserting if the AACDecoder is passed an unsupported config.
This commit is contained in:
@@ -778,7 +778,12 @@ status_t AwesomePlayer::initAudioDecoder() {
|
||||
}
|
||||
}
|
||||
|
||||
mAudioSource->start();
|
||||
status_t err = mAudioSource->start();
|
||||
|
||||
if (err != OK) {
|
||||
mAudioSource.clear();
|
||||
return err;
|
||||
}
|
||||
} else if (!strcasecmp(mime, MEDIA_MIMETYPE_AUDIO_QCELP)) {
|
||||
// For legacy reasons we're simply going to ignore the absence
|
||||
// of an audio decoder for QCELP instead of aborting playback
|
||||
|
||||
@@ -90,8 +90,10 @@ status_t AACDecoder::start(MetaData *params) {
|
||||
mConfig->pOutputBuffer_plus = NULL;
|
||||
mConfig->repositionFlag = false;
|
||||
|
||||
CHECK_EQ(PVMP4AudioDecoderConfig(mConfig, mDecoderBuf),
|
||||
MP4AUDEC_SUCCESS);
|
||||
if (PVMP4AudioDecoderConfig(mConfig, mDecoderBuf)
|
||||
!= MP4AUDEC_SUCCESS) {
|
||||
return ERROR_UNSUPPORTED;
|
||||
}
|
||||
}
|
||||
|
||||
mSource->start();
|
||||
|
||||
Reference in New Issue
Block a user