diff --git a/hgext/largefiles/lfutil.py b/hgext/largefiles/lfutil.py --- a/hgext/largefiles/lfutil.py +++ b/hgext/largefiles/lfutil.py @@ -319,6 +319,8 @@ def updatestandin(repo, standin): hash = hashfile(file) executable = getexecutable(file) writestandin(repo, standin, hash, executable) + else: + raise error.Abort(_('%s: file not found!') % splitstandin(standin)) def readstandin(repo, filename, node=None): '''read hex hash from standin for filename at given node, or working diff --git a/tests/test-largefiles-cache.t b/tests/test-largefiles-cache.t --- a/tests/test-largefiles-cache.t +++ b/tests/test-largefiles-cache.t @@ -19,6 +19,12 @@ Create source repo, and commit adding la $ hg rm large $ hg commit -m 'branchhead without largefile' large $ hg up -qr 0 + $ rm large + $ echo "0000000000000000000000000000000000000000" > .hglf/large + $ hg commit -m 'commit missing file with corrupt standin' large + abort: large: file not found! + [255] + $ hg up -Cqr 0 $ cd .. Discard all cached largefiles in USERCACHE