vcl/opengl/RenderList.cxx | 2 ++ 1 file changed, 2 insertions(+) New commits: commit 6cf3040fe180ae684a60655685a493843c2b162a Author: Tomaž Vajngerl <tomaz.vajng...@collabora.co.uk> Date: Thu Dec 8 17:49:54 2016 +0100
tdf#104034 skip polygons with less than 2 points We can get polypolgons with polygons that have 0 or 1 point only, so we need to guard agains division-by-zero errors by skipping if we detect such polygons (as we can't draw them anyway). Change-Id: Ia27fcde9467864b10572a78a848ea642a3559185 Reviewed-on: https://gerrit.libreoffice.org/31770 Reviewed-by: Tomaž Vajngerl <qui...@gmail.com> Tested-by: Tomaž Vajngerl <qui...@gmail.com> (cherry picked from commit cee552d2071601b6f4131eda9e9a0a17768ea272) Reviewed-on: https://gerrit.libreoffice.org/31789 diff --git a/vcl/opengl/RenderList.cxx b/vcl/opengl/RenderList.cxx index 5f99513..cef311f 100644 --- a/vcl/opengl/RenderList.cxx +++ b/vcl/opengl/RenderList.cxx @@ -326,6 +326,8 @@ void RenderList::addDrawPolyPolygon(const basegfx::B2DPolyPolygon& rPolyPolygon, aPolygon = rPolygon.getDefaultAdaptiveSubdivision(); sal_uInt32 nPoints = aPolygon.count(); + if (nPoints <= 1) + continue; GLfloat x1, y1, x2, y2; sal_uInt32 index1, index2;
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits