From 1f74a3ce201bad68f160584900285e2c087ab2c0 Mon Sep 17 00:00:00 2001 From: Kohei Yoshida Date: Wed, 19 Feb 2014 16:34:19 -0500 Subject: fdo#74584: Upcase the tag name before searching. Else HTML import or detection code would fail. Change-Id: Id79e8eac87d8001527f068f8fd49636353dc38d5 --- svtools/source/svhtml/htmlkywd.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/svtools/source/svhtml/htmlkywd.cxx b/svtools/source/svhtml/htmlkywd.cxx index c0b791567dc8..affbc86081a8 100644 --- a/svtools/source/svhtml/htmlkywd.cxx +++ b/svtools/source/svhtml/htmlkywd.cxx @@ -189,6 +189,7 @@ static int SAL_CALL HTMLKeyCompare( const void *pFirst, const void *pSecond) int GetHTMLToken( const OUString& rName ) { + OUString aNameUpper = rName.toAsciiUpperCase(); if( !bSortKeyWords ) { qsort( (void*) aHTMLTokenTab, @@ -200,12 +201,12 @@ int GetHTMLToken( const OUString& rName ) int nRet = 0; - if( !rName.compareTo( OOO_STRING_SVTOOLS_HTML_comment, 3 ) ) + if (!aNameUpper.compareTo(OOO_STRING_SVTOOLS_HTML_comment, 3)) return HTML_COMMENT; void* pFound; HTML_TokenEntry aSrch; - aSrch.pUToken = &rName; + aSrch.pUToken = &aNameUpper; aSrch.nToken = -1; pFound = bsearch( (sal_Char *) &aSrch, -- cgit