[PATCH 08 of 11] vfs: fix two setattr calls to use sysstrs
Augie Fackler
raf at durin42.com
Sun Mar 26 18:36:42 EDT 2017
# HG changeset patch
# User Augie Fackler <raf at durin42.com>
# Date 1490567343 14400
# Sun Mar 26 18:29:03 2017 -0400
# Node ID 8d683b05a16a94321d6c891ddc40f1bc3976db64
# Parent e7fe3ab60132647a9c3b86b2960b385e61b9dcf0
vfs: fix two setattr calls to use sysstrs
diff --git a/mercurial/vfs.py b/mercurial/vfs.py
--- a/mercurial/vfs.py
+++ b/mercurial/vfs.py
@@ -480,7 +480,7 @@ class closewrapbase(object):
Do not instantiate outside of the vfs layer.
"""
def __init__(self, fh):
- object.__setattr__(self, '_origfh', fh)
+ object.__setattr__(self, pycompat.sysstr('_origfh'), fh)
def __getattr__(self, attr):
return getattr(self._origfh, attr)
@@ -618,7 +618,8 @@ class checkambigatclosing(closewrapbase)
"""
def __init__(self, fh):
super(checkambigatclosing, self).__init__(fh)
- object.__setattr__(self, '_oldstat', util.filestat(fh.name))
+ object.__setattr__(self, pycompat.sysstr('_oldstat'),
+ util.filestat(fh.name))
def _checkambig(self):
oldstat = self._oldstat
More information about the Mercurial-devel
mailing list