diff options
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/filter/graphicfilter.cxx | 1 | ||||
-rw-r--r-- | vcl/source/graphic/UnoGraphicProvider.cxx | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx index 023c07ecb9a2..43feef35e5e2 100644 --- a/vcl/source/filter/graphicfilter.cxx +++ b/vcl/source/filter/graphicfilter.cxx @@ -1572,6 +1572,7 @@ Graphic GraphicFilter::ImportUnloadedGraphic(SvStream& rIStream) nGraphicContentSize = nStreamLength; pGraphicContent.reset(new sal_uInt8[nGraphicContentSize]); + rIStream.Seek(nStreamBegin); rIStream.ReadBytes(pGraphicContent.get(), nStreamLength); if (!rIStream.GetError()) diff --git a/vcl/source/graphic/UnoGraphicProvider.cxx b/vcl/source/graphic/UnoGraphicProvider.cxx index 8b9ccb93bf94..7adb183f5aa8 100644 --- a/vcl/source/graphic/UnoGraphicProvider.cxx +++ b/vcl/source/graphic/UnoGraphicProvider.cxx @@ -355,9 +355,6 @@ uno::Reference< ::graphic::XGraphic > SAL_CALL GraphicProvider::queryGraphic( co } } - if (bLazyRead && aFilterData.hasElements()) - bLazyRead = false; - SolarMutexGuard g; if( xIStm.is() ) @@ -396,7 +393,10 @@ uno::Reference< ::graphic::XGraphic > SAL_CALL GraphicProvider::queryGraphic( co aExtHeader.mapMode = nExtMapMode; WmfExternal *pExtHeader = nullptr; if ( nExtMapMode > 0 ) + { pExtHeader = &aExtHeader; + bLazyRead = false; + } ErrCode error = ERRCODE_NONE; if (bLazyRead) |