Changed the flag to xmlDocCopyNode (and similar routines), previously used

* tree.c: Changed the flag to xmlDocCopyNode (and similar routines),
  previously used only for recursion, to use a value of '2' to
  indicate copy properties & namespaces, but not children.
* xinclude.c: changed the handling of ranges to use the above new
  facility.  Fixes Bug 134268.
diff --git a/xinclude.c b/xinclude.c
index 3cf1f54..05e05ed 100644
--- a/xinclude.c
+++ b/xinclude.c
@@ -914,7 +914,8 @@
 	 */
 	if (level < 0) {
 	    while (level < 0) {
-	        tmp2 = xmlDocCopyNode(listParent, target, 0);
+	        /* copy must include namespaces and properties */
+	        tmp2 = xmlDocCopyNode(listParent, target, 2);
 	        xmlAddChild(tmp2, list);
 	        list = tmp2;
 	        listParent = listParent->parent;
@@ -960,7 +961,8 @@
 	    } else {	/* ending node not a text node */
 	        endLevel = level;	/* remember the level of the end node */
 		endFlag = 1;
-		tmp = xmlDocCopyNode(cur, target, 0);
+		/* last node - need to take care of properties + namespaces */
+		tmp = xmlDocCopyNode(cur, target, 2);
 		if (list == NULL) {
 		    list = tmp;
 		    listParent = cur->parent;
@@ -1007,7 +1009,11 @@
 		last = list = tmp;
 		listParent = cur->parent;
 	    } else {		/* Not text node */
-		tmp = xmlDocCopyNode(cur, target, 0);
+	        /*
+		 * start of the range - need to take care of
+		 * properties and namespaces
+		 */
+		tmp = xmlDocCopyNode(cur, target, 2);
 		list = last = tmp;
 		listParent = cur->parent;
 		if (index1 > 1) {	/* Do we need to position? */
@@ -1040,7 +1046,11 @@
 		    /* Humm, should not happen ! */
 		    break;
 		default:
-		    tmp = xmlDocCopyNode(cur, target, 0);
+		    /*
+		     * Middle of the range - need to take care of
+		     * properties and namespaces
+		     */
+		    tmp = xmlDocCopyNode(cur, target, 2);
 		    break;
 	    }
 	    if (tmp != NULL) {