• Glenn Kasten's avatar
    Don't update prepare state more than once · 0d1c7e2c
    Glenn Kasten authored
    If a MEDIA_ERROR event is received during preparation, it indicates
    that prepare has completed unsuccessfully.  However, MEDIA_ERROR can
    also legitimately be sent after successful prepare. In that case, don't
    update the prepare state.
    
    Similarly, in the unlikely case that MEDIA_PREPARED is received after
    prepare has already completed successfully or unsuccessfully, ignore it.
    This probably indicates a buggy mediaserver, but we wouldn't want that
    to take down the client also.
    
    Change-Id: I2a92e98d13b70d1aa5ff6f440ad528f6896a2ead
    0d1c7e2c
android_GenericMediaPlayer.cpp 17.8 KB