summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2018-10-20 21:29:38 +0100
committerCaolán McNamara <caolanm@redhat.com>2018-10-21 18:17:49 +0200
commit6837fbb1884cd8ad928ac028f9a94fad54dc1827 (patch)
tree144d36f19405ea4b8639ab631c6fcb64bf5bce2f
parentda3091d18cec68bdbb2f1c1418d9d2bd07683ab8 (diff)
pvs-studio: silence bogus V656
Change-Id: Ib54677e4172b8d2b789cf49ab964fbcc112869f8 Reviewed-on: https://gerrit.libreoffice.org/62110 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--vcl/source/control/edit.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/vcl/source/control/edit.cxx b/vcl/source/control/edit.cxx
index 895d35cef5e7..e92c2639b23d 100644
--- a/vcl/source/control/edit.cxx
+++ b/vcl/source/control/edit.cxx
@@ -727,9 +727,10 @@ void Edit::ImplDelete( const Selection& rSelection, sal_uInt8 nDirection, sal_uI
}
}
- maText.remove( static_cast<sal_Int32>(aSelection.Min()), static_cast<sal_Int32>(aSelection.Len()) );
- maSelection.Min() = aSelection.Min();
- maSelection.Max() = aSelection.Min();
+ const auto nSelectionMin = aSelection.Min();
+ maText.remove( static_cast<sal_Int32>(nSelectionMin), static_cast<sal_Int32>(aSelection.Len()) );
+ maSelection.Min() = nSelectionMin;
+ maSelection.Max() = nSelectionMin;
ImplAlignAndPaint();
mbInternModified = true;
}