largefiles: fix commit of specified file on non-windows
authorNa'Tosha Bard <natosha@unity3d.com>
Thu, 06 Oct 2011 11:10:06 +0200
changeset 15206 f85c76b16f27
parent 15205 4e5b7d130e76
child 15207 0f7f9f06c759
largefiles: fix commit of specified file on non-windows
hgext/largefiles/lfutil.py
--- a/hgext/largefiles/lfutil.py	Wed Oct 05 10:28:39 2011 +0200
+++ b/hgext/largefiles/lfutil.py	Thu Oct 06 11:10:06 2011 +0200
@@ -101,13 +101,9 @@
 
 # -- Private worker functions ------------------------------------------
 
-if os.name == 'nt':
-    from mercurial import win32
-    linkfn = win32.oslink
-
 def link(src, dest):
     try:
-        linkfn(src, dest)
+        util.oslink(src, dest)
     except OSError:
         # If hardlinks fail fall back on copy
         shutil.copyfile(src, dest)