Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Unified Diff: third_party/libxslt/libxslt/preproc.c

Issue 661058: libxslt update (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/src/
Patch Set: '' Created 10 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/libxslt/libxslt/pattern.c ('k') | third_party/libxslt/libxslt/security.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/libxslt/libxslt/preproc.c
===================================================================
--- third_party/libxslt/libxslt/preproc.c (revision 39981)
+++ third_party/libxslt/libxslt/preproc.c (working copy)
@@ -82,7 +82,7 @@
}
return(0);
}
- if ((parent->ns == NULL) ||
+ if ((parent->ns == NULL) || (parent->type != XML_ELEMENT_NODE) ||
((parent->ns != inst->ns) &&
(!xmlStrEqual(parent->ns->href, inst->ns->href))) ||
((!xmlStrEqual(parent->name, BAD_CAST "stylesheet")) &&
@@ -391,6 +391,8 @@
break;
case XSLT_FUNC_SORT: {
xsltStyleItemSortPtr item = (xsltStyleItemSortPtr) comp;
+ if (item->locale != (xsltLocale)0)
+ xsltFreeLocale(item->locale);
if (item->comp != NULL)
xmlXPathFreeCompExpr(item->comp);
}
@@ -487,6 +489,8 @@
break;
}
#else
+ if (comp->locale != (xsltLocale)0)
+ xsltFreeLocale(comp->locale);
if (comp->comp != NULL)
xmlXPathFreeCompExpr(comp->comp);
if (comp->nsList != NULL)
@@ -728,6 +732,12 @@
comp->lang = xsltEvalStaticAttrValueTemplate(style, inst,
(const xmlChar *)"lang",
NULL, &comp->has_lang);
+ if (comp->lang != NULL) {
+ comp->locale = xsltNewLocale(comp->lang);
+ }
+ else {
+ comp->locale = (xsltLocale)0;
+ }
comp->select = xsltGetCNsProp(style, inst,(const xmlChar *)"select", XSLT_NAMESPACE);
if (comp->select == NULL) {
« no previous file with comments | « third_party/libxslt/libxslt/pattern.c ('k') | third_party/libxslt/libxslt/security.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698