summaryrefslogtreecommitdiff
path: root/svl/source
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2022-10-21 18:48:27 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2022-10-22 08:28:33 +0200
commitdb8f0528eb71252b4af9c3f7ec213ea7fb29591a (patch)
treef42686e239fabe333903cb4a6e7383aece3e5143 /svl/source
parentac5f11d86cd290deaed3565c558aced9f5eb6fca (diff)
use more TempFileFastService in svl
Change-Id: I798a7bb773028aba059f058d4e65e7b2e845c015 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141647 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svl/source')
-rw-r--r--svl/source/fsstor/fsstorage.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/svl/source/fsstor/fsstorage.cxx b/svl/source/fsstor/fsstorage.cxx
index 8d2da219d7be..68e82feb0121 100644
--- a/svl/source/fsstor/fsstorage.cxx
+++ b/svl/source/fsstor/fsstorage.cxx
@@ -48,6 +48,7 @@
#include <unotools/ucbhelper.hxx>
#include <unotools/ucbstreamhelper.hxx>
#include <unotools/streamwrap.hxx>
+#include <unotools/tempfile.hxx>
#include <ucbhelper/content.hxx>
#include "fsstorage.hxx"
@@ -472,13 +473,10 @@ uno::Reference< io::XStream > SAL_CALL FSStorage::cloneStreamElement( const OUSt
::ucbhelper::Content aResultContent( aFileURL.GetMainURL( INetURLObject::DecodeMechanism::NONE ), xDummyEnv, comphelper::getProcessComponentContext() );
uno::Reference< io::XInputStream > xInStream = aResultContent.openStream();
- xTempResult = io::TempFile::create(m_xContext);
+ xTempResult = new utl::TempFileFastService;
uno::Reference < io::XOutputStream > xTempOut = xTempResult->getOutputStream();
uno::Reference < io::XInputStream > xTempIn = xTempResult->getInputStream();
- if ( !xTempOut.is() || !xTempIn.is() )
- throw io::IOException();
-
::comphelper::OStorageHelper::CopyInputToOutput( xInStream, xTempOut );
xTempOut->closeOutput();
}