mercurial/revlog.py
changeset 1509 46a07392cf28
parent 1494 249ca10d37f4
child 1533 3d11f81c9145
--- a/mercurial/revlog.py
+++ b/mercurial/revlog.py
@@ -784,6 +784,10 @@ class revlog:
                 continue
             delta = chunk[80:]
 
+            for p in (p1, p2):
+                if not p in self.nodemap:
+                    raise RevlogError(_("unknown parent %s") % short(p1))
+
             if not chain:
                 # retrieve the parent revision of the delta chain
                 chain = p1