In tree.c 3530 (libxml2 2.7.6), the function xmlPreviousElementSibling ends with:

    while (node != NULL) {
        if (node->type == XML_ELEMENT_NODE)
            return(node);
        node = node->next;
    }

I suggest
        node = node->prev;

François.
_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
[email protected]
http://mail.gnome.org/mailman/listinfo/xml

Reply via email to