fixed problem in previous fix to xmlXPathNodeSetSort

* xpath.c: fixed problem in previous fix to xmlXPathNodeSetSort

svn path=/trunk/; revision=3640
diff --git a/xpath.c b/xpath.c
index 8f6545a..9c4db87 100644
--- a/xpath.c
+++ b/xpath.c
@@ -3057,7 +3057,8 @@
 		precedence1 = 2; /* element is parent */
 		node1 = node1->parent;
 	    }
-	    if ((node1 == NULL) || (node1->type != XML_ELEMENT_NODE)) {
+	    if ((node1 == NULL) || (node1->type != XML_ELEMENT_NODE) ||
+		(0 <= (long) node1->content)) {
 		/*
 		* Fallback for whatever case.
 		*/
@@ -3194,11 +3195,6 @@
 
 turtle_comparison:
 
-    if (miscNode1 != NULL)
-	node1 = miscNode1;
-    if (miscNode2 != NULL)
-	node2 = miscNode2;
-
     if (node1 == node2->prev)
 	return(1);
     if (node1 == node2->next)