diff options
author | László Németh <nemeth@numbertext.org> | 2018-06-18 16:48:02 +0200 |
---|---|---|
committer | László Németh <nemeth@numbertext.org> | 2018-06-19 09:09:44 +0200 |
commit | 4cb1e86e5217f09e1d98e51e46803a06fb72f5ce (patch) | |
tree | 4c72d5d4081878ba83b9ba650f345e43e554e609 /svx | |
parent | 853350787df9a8d92c269ef1b6e764863e74ec2a (diff) |
tdf#103913 keep ".emf" file extension and mime type
in documents, don't change them to wmf and image/x-wmf
silently, resulting for example, dropping or rejecting
modified documents by firewall packet filtering.
Change-Id: I3b8634ae022c7c026b0ed4ebc345c1c3b3f96337
Reviewed-on: https://gerrit.libreoffice.org/56045
Reviewed-by: László Németh <nemeth@numbertext.org>
Tested-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/xml/xmlgrhlp.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/svx/source/xml/xmlgrhlp.cxx b/svx/source/xml/xmlgrhlp.cxx index b8428d2aeda4..8d010850165c 100644 --- a/svx/source/xml/xmlgrhlp.cxx +++ b/svx/source/xml/xmlgrhlp.cxx @@ -658,7 +658,12 @@ OUString SvXMLGraphicHelper::implSaveGraphic(css::uno::Reference<css::graphic::X case GfxLinkType::NativeJpg: aExtension = ".jpg"; break; case GfxLinkType::NativePng: aExtension = ".png"; break; case GfxLinkType::NativeTif: aExtension = ".tif"; break; - case GfxLinkType::NativeWmf: aExtension = ".wmf"; break; + case GfxLinkType::NativeWmf: + if (aGfxLink.IsEMF()) + aExtension = ".emf"; + else + aExtension = ".wmf"; + break; case GfxLinkType::NativeMet: aExtension = ".met"; break; case GfxLinkType::NativePct: aExtension = ".pct"; break; case GfxLinkType::NativeSvg: |