summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/omx/SoftVideoDecoderOMXComponent.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'media/libstagefright/omx/SoftVideoDecoderOMXComponent.cpp')
-rw-r--r--media/libstagefright/omx/SoftVideoDecoderOMXComponent.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/media/libstagefright/omx/SoftVideoDecoderOMXComponent.cpp b/media/libstagefright/omx/SoftVideoDecoderOMXComponent.cpp
index eb9fcf7..20a7076 100644
--- a/media/libstagefright/omx/SoftVideoDecoderOMXComponent.cpp
+++ b/media/libstagefright/omx/SoftVideoDecoderOMXComponent.cpp
@@ -177,18 +177,19 @@ OMX_ERRORTYPE SoftVideoDecoderOMXComponent::internalGetParameter(
{
OMX_VIDEO_PARAM_PROFILELEVELTYPE *profileLevel =
(OMX_VIDEO_PARAM_PROFILELEVELTYPE *) params;
+ OMX_U32 profileIndex = profileLevel->nProfileIndex;
if (profileLevel->nPortIndex != kInputPortIndex) {
ALOGE("Invalid port index: %" PRIu32, profileLevel->nPortIndex);
return OMX_ErrorUnsupportedIndex;
}
- if (index >= mNumProfileLevels) {
+ if (profileIndex >= mNumProfileLevels) {
return OMX_ErrorNoMore;
}
- profileLevel->eProfile = mProfileLevels[index].mProfile;
- profileLevel->eLevel = mProfileLevels[index].mLevel;
+ profileLevel->eProfile = mProfileLevels[profileIndex].mProfile;
+ profileLevel->eLevel = mProfileLevels[profileIndex].mLevel;
return OMX_ErrorNone;
}