diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-04-17 15:08:39 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-04-22 09:32:55 +0200 |
commit | be48e04b5bd51015595c0f0792a646c51164fd34 (patch) | |
tree | 3e54d8f8b1d88bf190d555561072d7d00159d028 /forms | |
parent | 29840e676927eb44c5857e854df283d58aae93c3 (diff) |
Elide const vars
Change-Id: I1b2a7b071f9740e8c848f543e32fd47f054c8318
Diffstat (limited to 'forms')
-rw-r--r-- | forms/source/xforms/xpathlib/xpathlib.cxx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/forms/source/xforms/xpathlib/xpathlib.cxx b/forms/source/xforms/xpathlib/xpathlib.cxx index cc14fbf10765..b5e498266c41 100644 --- a/forms/source/xforms/xpathlib/xpathlib.cxx +++ b/forms/source/xforms/xpathlib/xpathlib.cxx @@ -213,8 +213,6 @@ void xforms_indexFunction(xmlXPathParserContextPtr /*ctxt*/, int /*nargs*/) } // String Functions -static const char* _version = "1.0"; -static const char* _conformance = "conformance"; void xforms_propertyFunction(xmlXPathParserContextPtr ctxt, int nargs) { if (nargs != 1) XP_ERROR(XPATH_INVALID_ARITY); @@ -222,9 +220,9 @@ void xforms_propertyFunction(xmlXPathParserContextPtr ctxt, int nargs) if (xmlXPathCheckError(ctxt)) XP_ERROR(XPATH_INVALID_TYPE); OUString aString(reinterpret_cast<char*>(pString), strlen(reinterpret_cast<char*>(pString)), RTL_TEXTENCODING_UTF8); if (aString.equalsIgnoreAsciiCase("version")) - xmlXPathReturnString(ctxt, reinterpret_cast<xmlChar *>(const_cast<char *>(_version))); + xmlXPathReturnString(ctxt, reinterpret_cast<xmlChar *>(const_cast<char *>("1.0"))); else if (aString.equalsIgnoreAsciiCase("conformance-level")) - xmlXPathReturnString(ctxt, reinterpret_cast<xmlChar *>(const_cast<char *>(_conformance))); + xmlXPathReturnString(ctxt, reinterpret_cast<xmlChar *>(const_cast<char *>("conformance"))); else xmlXPathReturnEmptyString(ctxt); } |