1
From: Nick Wellnhofer <wellnhofer@aevum.de>
2
Date: Sat, 11 Jul 2015 14:27:34 +0200
3
Subject: Fix previous change to node sort order
5
Commit ba58f23 broke comparison of nodes from different documents.
6
Thanks to Olli Pottonen for the report.
9
1 file changed, 4 insertions(+), 4 deletions(-)
11
diff --git a/xpath.c b/xpath.c
12
index 95559b3..e60f4e5 100644
15
@@ -361,14 +361,14 @@ turtle_comparison:
17
* compute depth to root
19
- for (depth2 = 0, cur = node2; cur != NULL; cur = cur->parent) {
21
+ for (depth2 = 0, cur = node2; cur->parent != NULL; cur = cur->parent) {
22
+ if (cur->parent == node1)
27
- for (depth1 = 0, cur = node1; cur != NULL; cur = cur->parent) {
29
+ for (depth1 = 0, cur = node1; cur->parent != NULL; cur = cur->parent) {
30
+ if (cur->parent == node2)