[Libreoffice-commits] core.git: unusedcode.easy writerfilter/inc writerfilter/source

Miklos Vajna vmiklos at collabora.co.uk
Sun Jun 15 14:39:50 PDT 2014


 unusedcode.easy                            |    1 
 writerfilter/inc/resourcemodel/util.hxx    |    2 -
 writerfilter/source/resourcemodel/util.cxx |   30 -----------------------------
 3 files changed, 33 deletions(-)

New commits:
commit 5be3e84c88940c040645fd588038d34b09dcdcc5
Author: Miklos Vajna <vmiklos at collabora.co.uk>
Date:   Sun Jun 15 23:32:35 2014 +0200

    writerfilter: unused xmlify()
    
    Change-Id: I22649e1efa82ddd5fe90be84eee2e41996b3343d

diff --git a/unusedcode.easy b/unusedcode.easy
index f9019d6..a000178 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -215,4 +215,3 @@ writerfilter::XPathLogger::endElement()
 writerfilter::XPathLogger::getXPath() const
 writerfilter::XPathLogger::startElement(std::basic_string<char, std::char_traits<char>, std::allocator<char> >)
 writerfilter::ooxml::OOXMLParserState::getXPathLogger()
-writerfilter::xmlify(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
diff --git a/writerfilter/inc/resourcemodel/util.hxx b/writerfilter/inc/resourcemodel/util.hxx
index a77c7e8..24abfe8 100644
--- a/writerfilter/inc/resourcemodel/util.hxx
+++ b/writerfilter/inc/resourcemodel/util.hxx
@@ -26,8 +26,6 @@
 
 namespace writerfilter
 {
-    std::string xmlify(const std::string & str);
-
 #if OSL_DEBUG_LEVEL > 1
     std::string toString(css::uno::Reference< css::text::XTextRange > textRange);
 #endif
diff --git a/writerfilter/source/resourcemodel/util.cxx b/writerfilter/source/resourcemodel/util.cxx
index 956da48..4b5549e 100644
--- a/writerfilter/source/resourcemodel/util.cxx
+++ b/writerfilter/source/resourcemodel/util.cxx
@@ -36,36 +36,6 @@ namespace writerfilter
 using namespace com::sun::star;
 using namespace std;
 
-string xmlify(const string & str)
-{
-    string result = "";
-    char sBuffer[16];
-
-    for (string::const_iterator aIt = str.begin(); aIt != str.end(); ++aIt)
-    {
-        char c = *aIt;
-
-        if (isprint(c) && c != '\"')
-        {
-            if (c == '<')
-                result += "<";
-            else if (c == '>')
-                result += ">";
-            else if (c == '&')
-                result += "&";
-            else
-                result += c;
-        }
-        else
-        {
-            snprintf(sBuffer, sizeof(sBuffer), "\\%03d", c);
-            result += sBuffer;
-        }
-    }
-
-    return result;
-}
-
 #if OSL_DEBUG_LEVEL > 1
 
 string toString(uno::Reference< text::XTextRange > textRange)


More information about the Libreoffice-commits mailing list