svl/source/numbers/zforscan.cxx | 1 +
1 file changed, 1 insertion(+)
New commits:
commit 08cc4c64ed2d80ebae984463c1fb4c603b03e7d4
Author: Caolán McNamara <[email protected]>
Date: Wed Apr 19 09:55:12 2017 +0100
coverity#1405221 silence Out-of-bounds read
Change-Id: I39b84b1d0272c2e8aa606e8b2e9ab0d2d88c3586
Reviewed-on: https://gerrit.libreoffice.org/36671
Tested-by: Jenkins <[email protected]>
Reviewed-by: Caolán McNamara <[email protected]>
Tested-by: Caolán McNamara <[email protected]>
diff --git a/svl/source/numbers/zforscan.cxx b/svl/source/numbers/zforscan.cxx
index 7ba86595b068..4bf7f4838604 100644
--- a/svl/source/numbers/zforscan.cxx
+++ b/svl/source/numbers/zforscan.cxx
@@ -1703,6 +1703,7 @@ sal_Int32 ImpSvNumberformatScan::FinalScan( OUString&
rString )
{
sDiv += sStrArray[j++];
}
+ assert(j > 0 && "if i is 0, first iteration through loop
is guaranteed by surrounding if condition");
if (OUString::number(sDiv.toInt32()) == sDiv)
{
// Found a Divisor
_______________________________________________
Libreoffice-commits mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits