diff options
-rw-r--r-- | emfio/source/reader/emfreader.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/emfio/source/reader/emfreader.cxx b/emfio/source/reader/emfreader.cxx index ceb797f568b0..dcb8a2379148 100644 --- a/emfio/source/reader/emfreader.cxx +++ b/emfio/source/reader/emfreader.cxx @@ -1009,6 +1009,11 @@ namespace emfio } else if (aPointTypes[i] & PT_BEZIERTO) { + if (aPoints.size() - i < 3) + { + SAL_WARN("emfio", "EMF file error: Not enough Bezier points."); + break; + } tools::Polygon aPolygon(4); aPolygon[0] = maActPos; aPolygon[1] = aPoints[i++]; |