diff --git a/multimedia/audio/audio_cpp_standard/openslesPlayerNdk/ActsOpenslesPlayerNdkTest.cpp b/multimedia/audio/audio_cpp_standard/openslesPlayerNdk/ActsOpenslesPlayerNdkTest.cpp index fd1a3f3c65d222a6336f035cbe160c8d547249b3..1391c0df69094b80bb105d8a00285876988707f3 100644 --- a/multimedia/audio/audio_cpp_standard/openslesPlayerNdk/ActsOpenslesPlayerNdkTest.cpp +++ b/multimedia/audio/audio_cpp_standard/openslesPlayerNdk/ActsOpenslesPlayerNdkTest.cpp @@ -166,6 +166,10 @@ static SLresult OpenSlTest() } SLmillibel pLevel = 0; result = (*volumeItf)->GetVolumeLevel(volumeItf, &pLevel); + if (SL_RESULT_SUCCESS != result) { + AUDIO_INFO_LOG("OpenSlTest GetVolumeLevel result: %{public}lu", result); + return result; + } result = (*pcmPlayerObject)->GetInterface(pcmPlayerObject, SL_IID_OH_BUFFERQUEUE, &bufferQueueItf); if (SL_RESULT_SUCCESS != result) { AUDIO_INFO_LOG("OpenSlTest get bufferQueueItf result: %{public}lu", result);