summaryrefslogtreecommitdiffstats
path: root/sw/source/core/docnode/ndtbl1.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/docnode/ndtbl1.cxx')
-rw-r--r--sw/source/core/docnode/ndtbl1.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/sw/source/core/docnode/ndtbl1.cxx b/sw/source/core/docnode/ndtbl1.cxx
index 4d0e38b794ab..923999f647cb 100644
--- a/sw/source/core/docnode/ndtbl1.cxx
+++ b/sw/source/core/docnode/ndtbl1.cxx
@@ -1626,7 +1626,8 @@ void SwDoc::AdjustCellWidth( const SwCursor& rCursor,
}
fTotalWish += aWish[i];
}
- const sal_uInt16 nEqualWidth = nSelectedWidth / nCols;
+ assert(nCols);
+ const sal_uInt16 nEqualWidth = nCols ? nSelectedWidth / nCols : 0;
// bBalance: Distribute the width evenly
for (sal_uInt16 & rn : aWish)
if ( rn && bBalance )