diff --git a/hg b/hg
index 1b11da6ee69e065ee4f11f535e6d50b6ec8b36b7_aGc=..00ea3613f82c216b5f145087c344ff08d3f2675f_aGc= 100644
--- a/hg
+++ b/hg
@@ -250,7 +250,7 @@
     repo.addchangegroup(data)
 
 elif cmd == "addremove":
-    (c, a, d, u) = repo.diffdir(repo.root, repo.current)
+    (c, a, d, u) = repo.diffdir(repo.root)
     repo.add(a)
     repo.remove(d)
     
diff --git a/mercurial/commands.py b/mercurial/commands.py
index 1b11da6ee69e065ee4f11f535e6d50b6ec8b36b7_bWVyY3VyaWFsL2NvbW1hbmRzLnB5..00ea3613f82c216b5f145087c344ff08d3f2675f_bWVyY3VyaWFsL2NvbW1hbmRzLnB5 100644
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -70,7 +70,7 @@
 
 def checkout(ui, repo, changeset=None):
     '''checkout a given changeset or the current tip'''
-    (c, a, d, u) = repo.diffdir(repo.root, repo.current)
+    (c, a, d, u) = repo.diffdir(repo.root)
     if c or a or d:
         ui.warn("aborting (outstanding changes in working directory)\n")
         sys.exit(1)
@@ -160,7 +160,7 @@
 A = added
 R = removed
 ? = not tracked'''
-    (c, a, d, u) = repo.diffdir(repo.root, repo.current)
+    (c, a, d, u) = repo.diffdir(repo.root)
     (c, a, d, u) = map(lambda x: relfilter(repo, x), (c, a, d, u))
 
     for f in c: print "C", f
diff --git a/mercurial/hg.py b/mercurial/hg.py
index 1b11da6ee69e065ee4f11f535e6d50b6ec8b36b7_bWVyY3VyaWFsL2hnLnB5..00ea3613f82c216b5f145087c344ff08d3f2675f_bWVyY3VyaWFsL2hnLnB5 100644
--- a/mercurial/hg.py
+++ b/mercurial/hg.py
@@ -426,7 +426,7 @@
                 else:
                     self.warn("%s not tracked!\n")
         else:
-            (c, a, d, u) = self.diffdir(self.root, parent)
+            (c, a, d, u) = self.diffdir(self.root)
             commit = c + a
             remove = d
 
@@ -501,7 +501,7 @@
         self.dirstate.clear()
         self.dirstate.update([f for f,n in l], "n")
 
-    def diffdir(self, path, changeset):
+    def diffdir(self, path, changeset = None):
         changed = []
         added = []
         unknown = []
@@ -510,6 +510,9 @@
         if changeset:
             change = self.changelog.read(changeset)
             mf = self.manifest.read(change[0])
-
-        if changeset == self.current:
+            dc = dict.fromkeys(mf)
+        else:
+            changeset = self.dirstate.parents()[0]
+            change = self.changelog.read(changeset)
+            mf = self.manifest.read(change[0])
             dc = self.dirstate.copy()
@@ -515,6 +518,4 @@
             dc = self.dirstate.copy()
-        else:
-            dc = dict.fromkeys(mf)
 
         def fcmp(fn):
             t1 = file(os.path.join(self.root, fn)).read()
@@ -535,7 +536,7 @@
                     if not c:
                         if fcmp(fn):
                             changed.append(fn)
-                    if c[0] == 'i':
+                    elif c[0] == 'i':
                         if fn not in mf:
                             added.append(fn)
                         elif fcmp(fn):