fixed a bug newly introduced and pointed by Uwe Fechner in xmlCopyProp()

* tree.c: fixed a bug newly introduced and pointed by Uwe Fechner
  in xmlCopyProp()
Daniel
diff --git a/tree.c b/tree.c
index 6381143..20017f7 100644
--- a/tree.c
+++ b/tree.c
@@ -2890,7 +2890,8 @@
     /*
      * Try to handle IDs
      */
-    if ((target->doc != NULL) && (cur->doc != NULL) &&
+    if ((target!= NULL) && (cur!= NULL) &&
+	(target->doc != NULL) && (cur->doc != NULL) &&
 	(cur->doc->ids != NULL) && (cur->parent != NULL)) {
 	if (xmlIsID(cur->doc, cur->parent, cur)) {
 	    xmlChar *id;