bdiff: handle the possibility of an integer overflow when allocating
Differential Revision: https://phab.mercurial-scm.org/D1877
svnsubrepo: check if subrepo is missing when checking dirty state (
issue5657)
During an hg convert command, subrepos are not checked out. However, a
manifestmerge may occur during an hg convert if there is a merge
commit, which in particular will check the dirty state of subrepos.
Before this change, the lack of a checked out subrepo would error out.
This check for svn subrepos is modelled after
2fdea636f254 for git
subrepos.