chart2/source/view/charttypes/GL3DBarChart.cxx | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)
New commits: commit 8eef38d87d5a876b9628355289ab6ddf9915db89 Author: Caolán McNamara <caol...@redhat.com> Date: Fri Jan 23 15:02:31 2015 +0000 Resolves: fdo#88229 Crash when you try to create a bar chart GL3D Change-Id: I6390f8988ca287de19e9981053bdeb9473d1e3e1 (cherry picked from commit 05e7b1db351ee964d155e49c55de7db3c917083f) Reviewed-on: https://gerrit.libreoffice.org/14138 Tested-by: Markus Mohrhard <markus.mohrh...@googlemail.com> Reviewed-by: Markus Mohrhard <markus.mohrh...@googlemail.com> diff --git a/chart2/source/view/charttypes/GL3DBarChart.cxx b/chart2/source/view/charttypes/GL3DBarChart.cxx index 7924e48..7d3159b 100755 --- a/chart2/source/view/charttypes/GL3DBarChart.cxx +++ b/chart2/source/view/charttypes/GL3DBarChart.cxx @@ -650,8 +650,15 @@ void GL3DBarChart::create3DShapes(const boost::ptr_vector<VDataSeries>& rDataSer sal_Int32 nSeriesIndex = 0; sal_Int32 nMaxPointCount = 0; double nMaxVal = findMaxValue(rDataSeriesContainer)/100; - const VDataSeries& rFirstRow = *(rDataSeriesContainer.begin()); - mnBarsInRow = rFirstRow.getTotalPointCount(); + if (rDataSeriesContainer.empty()) + { + mnBarsInRow = 0; + } + else + { + const VDataSeries& rFirstRow = *(rDataSeriesContainer.begin()); + mnBarsInRow = rFirstRow.getTotalPointCount(); + } for (boost::ptr_vector<VDataSeries>::const_iterator itr = rDataSeriesContainer.begin(), itrEnd = rDataSeriesContainer.end(); itr != itrEnd; ++itr) {
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits