Kaydet (Commit) 3c0003c9 authored tarafından Julien Nabet's avatar Julien Nabet

tdf#125325: fix crash about index managements for dBase

See bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=151468

Pb is aSearch becomes invalid after _rList.erase(aSearch); line 101
so just test aReturn.GetIndexFileName() isn't empty

Change-Id: Iae5b3a7f76fe565f890bd23bfb2ce5d9c6134986
Reviewed-on: https://gerrit.libreoffice.org/72427
Tested-by: Jenkins
Reviewed-by: 's avatarJulien Nabet <serval2412@yahoo.fr>
üst 218d2ab4
......@@ -107,8 +107,7 @@ OTableIndex ODbaseIndexDialog::implRemoveIndex(const OUString& _rName, TableInde
else
_rDisplay.select(static_cast<sal_uInt16>(nPos));
}
OSL_ENSURE(!_bMustExist || (aSearch != _rList.end()), "ODbaseIndexDialog::implRemoveIndex : did not find the index!");
OSL_ENSURE(!_bMustExist || !aReturn.GetIndexFileName().isEmpty(), "ODbaseIndexDialog::implRemoveIndex : did not find the index!");
return aReturn;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment