Index: /trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java	(revision 2695)
+++ /trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java	(revision 2696)
@@ -486,4 +486,5 @@
         this.id = generateUniqueId();
         this.version = 0;
+        this.changesetId = 0; // reset changeset id on a new object
         this.setIncomplete(false);
     }
@@ -1003,10 +1004,23 @@
         setKeys(other.getKeys());
         id = other.id;
+        if (id <=0) {
+            // reset version and changeset id
+            version = 0;
+            changesetId = 0;
+        }
         timestamp = other.timestamp;
-        version = other.version;
+        if (id > 0) {
+            version = other.version;
+        }
         setIncomplete(other.isIncomplete());
         flags = other.flags;
         user= other.user;
-        setChangesetId(other.changesetId);
+        if (id > 0 && other.changesetId > 0) {
+            // #4208: sometimes we cloned from other with id < 0 *and*
+            // an assigned changeset id. Don't know why yet. For primitives
+            // with id < 0 we don't propagate the changeset id any more.
+            //
+            setChangesetId(other.changesetId);
+        }
         clearCached();
     }
@@ -1030,4 +1044,5 @@
         if (! other.isNew() && other.getId() != id)
             throw new DataIntegrityProblemException(tr("Can''t merge primitives with different ids. This id is {0}, the other is {1}", id, other.getId()));
+
         setKeys(other.getKeys());
         timestamp = other.timestamp;
@@ -1036,5 +1051,5 @@
         flags = other.flags;
         user= other.user;
-        setChangesetId(other.changesetId);
+        changesetId = other.changesetId;
     }
 
