Commit 30385f0f by Nicolas Capens

Fix buffer overflow.

Bug chromium:712624 Change-Id: I8e7813aac44c9fef1a2311be550da8cea5a65d16 Reviewed-on: https://swiftshader-review.googlesource.com/9330Reviewed-by: 's avatarNicolas Capens <capn@google.com> Tested-by: 's avatarNicolas Capens <capn@google.com>
parent 59dca946
......@@ -1152,7 +1152,8 @@ namespace sw
{
if(Ice::isVectorType(T(Ty)))
{
int64_t c[4] = {0, 0, 0, 0};
assert(Ice::typeNumElements(T(Ty)) <= 16);
int64_t c[16] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
return createConstantVector(c, Ty);
}
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment