Mercurial > hg-stable
changeset 5543:a3df02cd4a35
push/pull: abort if we try to visit a missing or empty revlog
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Wed, 21 Nov 2007 13:26:18 -0600 |
parents | 253736bb0dc9 |
children | 686899a7de5b |
files | mercurial/localrepo.py |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/localrepo.py Tue Nov 20 15:54:25 2007 -0600 +++ b/mercurial/localrepo.py Wed Nov 21 13:26:18 2007 -0600 @@ -1710,6 +1710,8 @@ # Go through all our files in order sorted by name. for fname in changedfiles: filerevlog = self.file(fname) + if filerevlog.count() == 0: + raise util.abort(_("empty or missing revlog for %s") % fname) # Toss out the filenodes that the recipient isn't really # missing. if msng_filenode_set.has_key(fname): @@ -1794,6 +1796,8 @@ for fname in changedfiles: filerevlog = self.file(fname) + if filerevlog.count() == 0: + raise util.abort(_("empty or missing revlog for %s") % fname) nodeiter = gennodelst(filerevlog) nodeiter = list(nodeiter) if nodeiter: