diff options
-rw-r--r-- | Lib/tempfile.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/tempfile.py b/Lib/tempfile.py index 1f30126..68cc896 100644 --- a/Lib/tempfile.py +++ b/Lib/tempfile.py @@ -120,7 +120,8 @@ class TemporaryFileWrapper: def __getattr__(self, name): file = self.__dict__['file'] a = getattr(file, name) - setattr(self, name, a) + if type(a) != type(0): + setattr(self, name, a) return a |