mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Fix incorrect vertices colors length check (flutter/engine#8247)
A DCHECK was checking incorrect values, and this corrects it.
This commit is contained in:
parent
bc628fa30f
commit
f55eee2dd9
@ -73,7 +73,7 @@ void Vertices::init(SkVertices::VertexMode vertex_mode,
|
||||
}
|
||||
if (colors.data()) {
|
||||
// SkVertices::Builder assumes equal numbers of elements
|
||||
FML_DCHECK(positions.num_elements() == colors.num_elements());
|
||||
FML_DCHECK(positions.num_elements() / 2 == colors.num_elements());
|
||||
DecodeInts<SkColor>(colors, builder.colors());
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user