Hi,
I have submitted a patch for review:
https://gerrit.libreoffice.org/2907
To pull it, you can do:
git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/07/2907/1
get rid of two-argument compareToAscii
As I don't see a point in comparing a mimetype with only a
substring, it probably could be a simple compareToAscii, but
play it save and use startsWith.
Change-Id: Ic33c8089283def615999ddf80cd12f6fe219ed17
---
M vcl/aqua/source/dtrans/DataFlavorMapping.cxx
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
index a1a69ff..6cfc2c9 100644
--- a/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
+++ b/vcl/aqua/source/dtrans/DataFlavorMapping.cxx
@@ -526,7 +526,7 @@
for (size_t i = 0; i < SIZE_FLAVOR_MAP; i++)
{
- if (oOOFlavor.MimeType.compareToAscii(flavorMap[i].OOoFlavor,
strlen(flavorMap[i].OOoFlavor)) == 0)
+ if (oOOFlavor.MimeType.startsWith(flavorMap[i].OOoFlavor))
{
sysFlavor = flavorMap[i].SystemFlavor;
}
--
To view, visit https://gerrit.libreoffice.org/2907
To unsubscribe, visit https://gerrit.libreoffice.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic33c8089283def615999ddf80cd12f6fe219ed17
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
Context
- [PATCH] get rid of two-argument compareToAscii · Christian Lohmaier (via Code Review)
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.