summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJens Carl <j.carl43@gmx.de>2017-12-08 09:09:39 +0000
committerEike Rathke <erack@redhat.com>2017-12-08 15:46:35 +0100
commitd51e7581d90d55b5fe9a0f175d3cbee32de51721 (patch)
tree265139134cf1652c95b39eb3e3527ad28203c81c
parenta58c44457b26b3c95e30d609704bcb9a05a35f6b (diff)
Fix segfault when ScDBDocFunc::AddDBRange is called ...
multiple time with same name. ScDBCollection::NamedDBs::insert() use an unique_ptr to hold ScDBData* and if the insert isn't a success we don't have clean up with delete. Change-Id: I9b24834ea2e2dfd67b07438e6c4789ad0c01b888 Reviewed-on: https://gerrit.libreoffice.org/46075 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins <ci@libreoffice.org>
-rw-r--r--sc/source/ui/docshell/dbdocfun.cxx1
1 files changed, 0 insertions, 1 deletions
diff --git a/sc/source/ui/docshell/dbdocfun.cxx b/sc/source/ui/docshell/dbdocfun.cxx
index 0d424c08282f..02090556c614 100644
--- a/sc/source/ui/docshell/dbdocfun.cxx
+++ b/sc/source/ui/docshell/dbdocfun.cxx
@@ -96,7 +96,6 @@ bool ScDBDocFunc::AddDBRange( const OUString& rName, const ScRange& rRange )
if (!bOk)
{
- delete pNew;
delete pUndoColl;
return false;
}