Index: trunk/src/org/openstreetmap/josm/actions/UpdateSelectionAction.java
===================================================================
--- trunk/src/org/openstreetmap/josm/actions/UpdateSelectionAction.java	(revision 2470)
+++ trunk/src/org/openstreetmap/josm/actions/UpdateSelectionAction.java	(revision 2471)
@@ -10,4 +10,5 @@
 import java.util.Collection;
 import java.util.Collections;
+import java.util.logging.Logger;
 
 import javax.swing.JOptionPane;
@@ -138,4 +139,6 @@
      */
     static class UpdatePrimitivesTask extends PleaseWaitRunnable {
+        static private final Logger logger = Logger.getLogger(UpdatePrimitivesTask.class.getName());
+
         private DataSet ds;
         private boolean canceled;
@@ -144,4 +147,8 @@
         private MultiFetchServerObjectReader reader;
 
+        /**
+         * 
+         * @param toUpdate a collection of primitives to update from the server
+         */
         public UpdatePrimitivesTask(Collection<? extends OsmPrimitive> toUpdate) {
             super(tr("Update objects"), false /* don't ignore exception*/);
@@ -166,7 +173,7 @@
                 return;
             }
-            if (ds != null) {
-                Main.map.mapView.getEditLayer().mergeFrom(ds);
-                Main.map.mapView.getEditLayer().onPostDownloadFromServer();
+            if (ds != null && Main.main.getEditLayer() != null) {
+                Main.main.getEditLayer().mergeFrom(ds);
+                Main.main.getEditLayer().onPostDownloadFromServer();
             }
         }
@@ -202,4 +209,5 @@
             }
         }
+
 
         @Override
Index: trunk/src/org/openstreetmap/josm/data/osm/DataSetMerger.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/osm/DataSetMerger.java	(revision 2470)
+++ trunk/src/org/openstreetmap/josm/data/osm/DataSetMerger.java	(revision 2471)
@@ -83,7 +83,7 @@
             if (mergeById(source))
                 return;
-            if (!source.isVisible())
-                // ignore it
-                return;
+            //if (!source.isVisible())
+            // ignore it
+            //    return;
         } else {
             // try to merge onto a primitive  which has no id assigned
@@ -236,5 +236,5 @@
      * Tries to merge a primitive <code>source</code> into an existing primitive with the same id.
      *
-     * @param source  the other primitive which is to be merged onto a primitive in my primitives
+     * @param source  the source primitive which is to be merged into a target primitive
      * @return true, if this method was able to merge <code>source</code> into a target object; false, otherwise
      */
Index: trunk/src/org/openstreetmap/josm/data/osm/User.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/osm/User.java	(revision 2470)
+++ trunk/src/org/openstreetmap/josm/data/osm/User.java	(revision 2471)
@@ -7,4 +7,5 @@
 import java.util.HashMap;
 import java.util.List;
+import java.util.concurrent.atomic.AtomicLong;
 
 /**
@@ -18,5 +19,7 @@
  */
 public class User {
-    static private long uidCounter = 0;
+
+    static private AtomicLong uidCounter = new AtomicLong();
+
     /**
      * the map of known users
@@ -27,6 +30,5 @@
     private static long getNextLocalUid() {
         synchronized(User.class) {
-            uidCounter--;
-            return uidCounter;
+            return uidCounter.decrementAndGet();
         }
     }
@@ -60,4 +62,11 @@
     }
 
+    /**
+     * clears the static map of user ids to user objects
+     * 
+     */
+    public static void clearUserMap() {
+        userMap.clear();
+    }
 
     /**
Index: trunk/test/unit/org/openstreetmap/josm/data/osm/DataSetMergerTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/data/osm/DataSetMergerTest.java	(revision 2470)
+++ trunk/test/unit/org/openstreetmap/josm/data/osm/DataSetMergerTest.java	(revision 2471)
@@ -17,4 +17,5 @@
 import java.util.logging.Logger;
 
+import org.junit.Before;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -62,4 +63,9 @@
     }
 
+    @Before
+    public void setUp() {
+        User.clearUserMap();
+    }
+
     /**
      * two identical nodes, even in id and version. No confict expected.
@@ -348,5 +354,6 @@
     /**
      * their node is not visible and doesn't exist in my data set
-     * => ignore their node
+     * => we can't ignore it because we'd run into troubles in case of multi fetch
+     * which can return invisible objects
      *
      */
@@ -373,5 +380,5 @@
         Node n2 = (Node)my.getPrimitiveById(1,OsmPrimitiveType.NODE);
         assertEquals(0,visitor.getConflicts().size());
-        assertEquals(1, my.getNodes().size());
+        assertEquals(2, my.getNodes().size());
         assertEquals(n,n2);
     }
@@ -775,5 +782,6 @@
         theirWay.addNode(n3);
         theirWay.addNode(n4);
-        theirWay.setUser(User.createOsmUser(1111, "their"));
+        User user = User.createOsmUser(1111, "their");
+        theirWay.setUser(user);
         theirWay.setTimestamp(new Date());
         their.addPrimitive(theirWay);
@@ -895,5 +903,9 @@
         theirWay.addNode(n4);
         theirWay.addNode(n5);
-        theirWay.setUser(User.createOsmUser(1111, "their"));
+        User user = User.getById(1111);
+        if (user == null) {
+            User.createOsmUser(1111, "their");
+        }
+        theirWay.setUser(user);
         theirWay.setTimestamp(new Date());
         their.addPrimitive(theirWay);
@@ -1081,3 +1093,4 @@
         assertTrue(!w.getNode(1).incomplete);
     }
+
 }
