changeset 19895:37c0d93fb166

bookmarks: use "vfs.unlink()" instead of "util.unlink()"
author FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
date Tue, 15 Oct 2013 00:51:04 +0900
parents df91e2df6ba3
children af03279c766a
files mercurial/bookmarks.py mercurial/scmutil.py
diffstat 2 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/bookmarks.py	Thu Oct 03 18:01:21 2013 +0200
+++ b/mercurial/bookmarks.py	Tue Oct 15 00:51:04 2013 +0900
@@ -126,7 +126,7 @@
     wlock = repo.wlock()
     try:
         try:
-            util.unlink(repo.join('bookmarks.current'))
+            repo.vfs.unlink('bookmarks.current')
             repo._bookmarkcurrent = None
         except OSError, inst:
             if inst.errno != errno.ENOENT:
--- a/mercurial/scmutil.py	Thu Oct 03 18:01:21 2013 +0200
+++ b/mercurial/scmutil.py	Tue Oct 15 00:51:04 2013 +0900
@@ -271,6 +271,9 @@
     def stat(self, path=None):
         return os.stat(self.join(path))
 
+    def unlink(self, path=None):
+        return util.unlink(self.join(path))
+
 class vfs(abstractvfs):
     '''Operate files relative to a base directory