summaryrefslogtreecommitdiff
path: root/unotools
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2014-10-10 17:54:58 +0200
committerMichael Stahl <mstahl@redhat.com>2014-10-11 00:28:48 +0200
commitf0215dcc9e5ba47d4b7d5b9759f1bd774942d388 (patch)
treecfdc5f141aebb1f92ee9949dc7d71b824503adea /unotools
parent124a29f0f8dd805ef1d67bd062e1978a8a88e759 (diff)
unotools: assert if TempFile::GetURL() fails due to missing file UCP
Change-Id: I3dd844c656766835079bc191b3b55d3fba2c2219
Diffstat (limited to 'unotools')
-rw-r--r--unotools/source/ucbhelper/tempfile.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/unotools/source/ucbhelper/tempfile.cxx b/unotools/source/ucbhelper/tempfile.cxx
index 8acc2e48b5ab..7665b3d81432 100644
--- a/unotools/source/ucbhelper/tempfile.cxx
+++ b/unotools/source/ucbhelper/tempfile.cxx
@@ -364,9 +364,9 @@ OUString TempFile::GetURL()
{
if ( aURL.isEmpty() )
{
- OUString aTmp;
- LocalFileHelper::ConvertPhysicalNameToURL( GetFileName(), aTmp );
- aURL = aTmp;
+ OUString const name(GetFileName());
+ LocalFileHelper::ConvertPhysicalNameToURL(name, aURL);
+ assert((name.isEmpty() || !aURL.isEmpty()) && "TempFile::GetURL failed: unit test is leaking temp files, add the ucpfile1 component!");
}
return aURL;