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

Commit 5aab3b82 authored by Vignesh Venkatasubramanian's avatar Vignesh Venkatasubramanian Committed by Automerger Merge Worker
Browse files

C2SoftGav1Dec: Disallow bitdepth > 10 am: abbb2177

parents e9b0fe49 abbb2177
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -781,6 +781,14 @@ bool C2SoftGav1Dec::outputBuffer(const std::shared_ptr<C2BlockPool> &pool,
    return false;
  }

  if (buffer->bitdepth > 10) {
    ALOGE("bitdepth %d is not supported", buffer->bitdepth);
    mSignalledError = true;
    work->workletsProcessed = 1u;
    work->result = C2_CORRUPTED;
    return false;
  }

  const int width = buffer->displayed_width[0];
  const int height = buffer->displayed_height[0];
  if (width != mWidth || height != mHeight) {