Show More
@@ -20,7 +20,7 b' from mercurial import pathutil' | |||||
20 |
|
20 | |||
21 | class state(object): |
|
21 | class state(object): | |
22 | def __init__(self, repo): |
|
22 | def __init__(self, repo): | |
23 |
self._ |
|
23 | self._vfs = repo.vfs | |
24 | self._ui = repo.ui |
|
24 | self._ui = repo.ui | |
25 | self._rootdir = pathutil.normasprefix(repo.root) |
|
25 | self._rootdir = pathutil.normasprefix(repo.root) | |
26 | self._lastclock = None |
|
26 | self._lastclock = None | |
@@ -33,7 +33,7 b' class state(object):' | |||||
33 |
|
33 | |||
34 | def get(self): |
|
34 | def get(self): | |
35 | try: |
|
35 | try: | |
36 |
file = self._ |
|
36 | file = self._vfs('fsmonitor.state', 'rb') | |
37 | except IOError as inst: |
|
37 | except IOError as inst: | |
38 | if inst.errno != errno.ENOENT: |
|
38 | if inst.errno != errno.ENOENT: | |
39 | raise |
|
39 | raise | |
@@ -91,7 +91,7 b' class state(object):' | |||||
91 | return |
|
91 | return | |
92 |
|
92 | |||
93 | try: |
|
93 | try: | |
94 |
file = self._ |
|
94 | file = self._vfs('fsmonitor.state', 'wb', atomictemp=True) | |
95 | except (IOError, OSError): |
|
95 | except (IOError, OSError): | |
96 | self._ui.warn(_("warning: unable to write out fsmonitor state\n")) |
|
96 | self._ui.warn(_("warning: unable to write out fsmonitor state\n")) | |
97 | return |
|
97 | return |
General Comments 0
You need to be logged in to leave comments.
Login now