do you think you will
spend the next week-end debugging the problem ?
Could it be as simple as reversing the polarity?
Er, I mean, adding the line shown below to functions.c?
Seemed to fix the problem, but whether running the
test suite inspires confidence or not, I don't know.
I couldn't immediately spot any tests that exercise
this function...
I'm unfamiliar with *nix customs for patch submitting,
and the process was not immediately clear from
the "how to help" web pages for libxslt (which seem
to say "ask first" anyway...).
void
xsltElementAvailableFunction(xmlXPathParserContextPtr ctxt, int nargs){
xmlXPathObjectPtr obj;
xmlChar *prefix, *name;
const xmlChar *nsURI = NULL;
xsltTransformContextPtr tctxt;
if (nargs != 1) {
xsltTransformError(xsltXPathGetTransformContext(ctxt), NULL, NULL,
"element-available() : expects one string arg\n");
ctxt->error = XPATH_INVALID_ARITY;
return;
}
/******** ADDED THE FOLLOWING LINE ********/
xmlXPathStringFunction(ctxt, 1);
if ((ctxt->value == NULL) || (ctxt->value->type != XPATH_STRING)) {
xsltTransformError(xsltXPathGetTransformContext(ctxt), NULL, NULL,
"element-available() : invalid arg expecting a string\n");
ctxt->error = XPATH_INVALID_TYPE;
return;
}
_______________________________________________
xslt mailing list, project page http://xmlsoft.org/XSLT/
[email protected]
http://mail.gnome.org/mailman/listinfo/xslt