diff options
| author | Johan B. C. Engelen <jbc.engelen@swissonline.ch> | 2012-05-25 23:32:52 +0000 |
|---|---|---|
| committer | Johan B. C. Engelen <j.b.c.engelen@alumnus.utwente.nl> | 2012-05-25 23:32:52 +0000 |
| commit | ffa974cd8dbace984f3879ae280650a3dbeff78a (patch) | |
| tree | 67fc862dbea6ed9a621606edcd35e7b56965c944 /src/gradient-chemistry.cpp | |
| parent | gradient mesh: add NULL checks to fix crash? (diff) | |
| download | inkscape-ffa974cd8dbace984f3879ae280650a3dbeff78a.tar.gz inkscape-ffa974cd8dbace984f3879ae280650a3dbeff78a.zip | |
mesh gradient: fix bad indexing
(bzr r11417)
Diffstat (limited to 'src/gradient-chemistry.cpp')
| -rw-r--r-- | src/gradient-chemistry.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gradient-chemistry.cpp b/src/gradient-chemistry.cpp index 6b1fcd627..6b1376fb5 100644 --- a/src/gradient-chemistry.cpp +++ b/src/gradient-chemistry.cpp @@ -717,6 +717,9 @@ guint32 sp_item_gradient_stop_query_style(SPItem *item, GrPointType point_type, switch (point_type) { case POINT_MG_CORNER: { + if (point_i >= mg->array.corners.size()) { + return 0; + } SPMeshNode const* cornerpoint = mg->array.corners[ point_i ]; if (cornerpoint) { |
