--- a/hgext/largefiles/overrides.py Thu Nov 24 18:22:45 2011 +0100
+++ b/hgext/largefiles/overrides.py Fri Nov 25 02:11:12 2011 +0100
@@ -619,11 +619,13 @@
f = lfutil.splitstandin(f)
def getdatafn():
+ fd = None
try:
fd = open(path, 'rb')
return fd.read()
finally:
- fd.close()
+ if fd:
+ fd.close()
getdata = getdatafn
write(f, 'x' in ff and 0755 or 0644, 'l' in ff, getdata)
--- a/tests/test-largefiles.t Thu Nov 24 18:22:45 2011 +0100
+++ b/tests/test-largefiles.t Fri Nov 25 02:11:12 2011 +0100
@@ -259,12 +259,6 @@
5 files updated, 0 files merged, 0 files removed, 0 files unresolved
getting changed largefiles
3 largefiles updated, 0 removed
- $ hg debugstate --nodates
- n 644 41 .hglf/sub/large4
- n 0 -1 .hglf/sub2/large6
- n 0 -1 .hglf/sub2/large7
- n 644 9 normal3
- n 644 9 sub/normal4
$ cd ../b
$ hg log --template '{rev}:{node|short} {desc|firstline}\n'
7:daea875e9014 add/edit more largefiles