Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d34a9dfc authored by Andy Hung's avatar Andy Hung Committed by android-build-merger
Browse files

Check effect command reply size in AudioFlinger am: 110bc954 am: 075c8f77...

Check effect command reply size in AudioFlinger am: 110bc954 am: 075c8f77 am: c971a59f am: 195f7c61
am: 1e1b7e4c

Change-Id: I6558d45c768225007c53016542459cec3dd1387f
parents f9b986af 1e1b7e4c
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -550,6 +550,12 @@ status_t AudioFlinger::EffectModule::command(uint32_t cmdCode,
    if (mStatus != NO_ERROR) {
        return mStatus;
    }
    if (cmdCode == EFFECT_CMD_GET_PARAM &&
            (*replySize < sizeof(effect_param_t) ||
                    ((effect_param_t *)pCmdData)->psize > *replySize - sizeof(effect_param_t))) {
        android_errorWriteLog(0x534e4554, "29251553");
        return -EINVAL;
    }
    status_t status = (*mEffectInterface)->command(mEffectInterface,
                                                   cmdCode,
                                                   cmdSize,