mirror of
https://github.com/darlinghq/darling-libxml2.git
synced 2025-03-03 16:55:55 +00:00
XMl Shell command "cd" does not handle "/" at end of path
For https://bugzilla.gnome.org/show_bug.cgi?id=731832 small fix
This commit is contained in:
parent
1811add768
commit
23243301a6
@ -3243,7 +3243,12 @@ xmlShell(xmlDocPtr doc, char *filename, xmlShellReadlineFunc input,
|
||||
ctxt->node = (xmlNodePtr) ctxt->doc;
|
||||
} else {
|
||||
#ifdef LIBXML_XPATH_ENABLED
|
||||
int l;
|
||||
|
||||
ctxt->pctxt->node = ctxt->node;
|
||||
l = strlen(arg);
|
||||
if ((l >= 2) && (arg[l - 1] == '/'))
|
||||
arg[l - 1] = 0;
|
||||
list = xmlXPathEval((xmlChar *) arg, ctxt->pctxt);
|
||||
#else
|
||||
list = NULL;
|
||||
|
Loading…
x
Reference in New Issue
Block a user