[Libreoffice-commits] core.git: dbaccess/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Mar 27 10:50:41 UTC 2020


 dbaccess/source/ui/dlg/indexdialog.cxx |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit fdb1dc8062f969f4dde038d116b631479ec796b6
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Mar 27 09:20:49 2020 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Mar 27 11:49:58 2020 +0100

    cid#1460977 Unchecked return value
    
    Change-Id: I8399df5aabae57df79c5e45a9b85fead482cde8e
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91196
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/dbaccess/source/ui/dlg/indexdialog.cxx b/dbaccess/source/ui/dlg/indexdialog.cxx
index fd27f35efbdd..fb698aabd6e2 100644
--- a/dbaccess/source/ui/dlg/indexdialog.cxx
+++ b/dbaccess/source/ui/dlg/indexdialog.cxx
@@ -354,10 +354,10 @@ namespace dbaui
 
     void DbaIndexDialog::OnRenameIndex()
     {
-        // the selected index
+        // the selected iterator
         std::unique_ptr<weld::TreeIter> xSelected(m_xIndexList->make_iterator());
-        // the selected index
-        m_xIndexList->get_selected(xSelected.get());
+        if (!m_xIndexList->get_selected(xSelected.get()))
+            return;
 
         // save the changes made 'til here
         // Upon leaving the edit mode, the control will be re-initialized with the


More information about the Libreoffice-commits mailing list