summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vcl/source/filter/graphicfilter.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx
index 870c5586ea82..072c1c31e5c8 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -1667,11 +1667,10 @@ Graphic GraphicFilter::ImportUnloadedGraphic(SvStream& rIStream)
}
// Set error code or try to set native buffer
- if(nStatus != ERRCODE_NONE)
- {
+ if (nStatus != ERRCODE_NONE)
ImplSetError(nStatus, &rIStream);
+ if (nStatus != ERRCODE_NONE || eLinkType == GfxLinkType::NONE)
rIStream.Seek(nStreamBegin);
- }
return aGraphic;
}