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

Commit 31b0c9cb authored by Mikhail Naganov's avatar Mikhail Naganov Committed by Android (Google) Code Review
Browse files

Merge "Add EFFECT_CMD_SET_PARAM parameter checking to Preset Reverb" into lmp-mr1-dev

parents fea0a3bb ee804dfa
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1768,6 +1768,10 @@ int Reverb_setParameter (ReverbContext *pContext, void *pParam, void *pValue, in
        if (param != REVERB_PARAM_PRESET) {
            return -EINVAL;
        }
        if (vsize < (int)sizeof(uint16_t)) {
            android_errorWriteLog(0x534e4554, "67647856");
            return -EINVAL;
        }

        uint16_t preset = *(uint16_t *)pValue;
        ALOGV("set REVERB_PARAM_PRESET, preset %d", preset);