diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2017-09-20 22:04:19 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2017-09-22 11:08:26 +0200 |
commit | 52230cb62d2784a5e5eae6f9982a7d1b2d8e43e9 (patch) | |
tree | afc53fb45d554e95567888509827e7376bf2b7cc | |
parent | f289357c6bc5e145e05075de4749591a05c37844 (diff) |
Related tdf#112423: avoid crash when calling procedure twice (dbaccess)
Since SbaTableQueryBrowser::implSelect returns a bool to indicate if everything is ok,
should return false when we entered in a catch
Change-Id: I9ae3ff3bf082278edb16a9b91701d6cf457e7179
Reviewed-on: https://gerrit.libreoffice.org/42601
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
-rw-r--r-- | dbaccess/source/ui/browser/unodatbr.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx index c57cea8ab205..7e5a7b22eb9e 100644 --- a/dbaccess/source/ui/browser/unodatbr.cxx +++ b/dbaccess/source/ui/browser/unodatbr.cxx @@ -2687,6 +2687,7 @@ bool SbaTableQueryBrowser::implSelect( SvTreeListEntry* _pEntry ) // reset the values xRowSetProps->setPropertyValue(PROPERTY_DATASOURCENAME,Any()); xRowSetProps->setPropertyValue(PROPERTY_ACTIVE_CONNECTION,Any()); + bSuccess = false; } catch(WrappedTargetException& e) { @@ -2698,12 +2699,14 @@ bool SbaTableQueryBrowser::implSelect( SvTreeListEntry* _pEntry ) // reset the values xRowSetProps->setPropertyValue(PROPERTY_DATASOURCENAME,Any()); xRowSetProps->setPropertyValue(PROPERTY_ACTIVE_CONNECTION,Any()); + bSuccess = false; } catch(const Exception&) { // reset the values xRowSetProps->setPropertyValue(PROPERTY_DATASOURCENAME,Any()); xRowSetProps->setPropertyValue(PROPERTY_ACTIVE_CONNECTION,Any()); + bSuccess = false; } } return bSuccess; |