Ticket #8175: close_open_trap.diff
File close_open_trap.diff, 580 bytes (added by , 16 years ago) |
---|
-
django/core/files/base.py
144 144 self.file.flush() 145 145 146 146 def close(self): 147 self.file.close() 147 if self._closed: 148 return 149 try: 150 if self.file: 151 self.file.close() 152 except IOError: 153 #file is not there or went away .. so it's closed 154 pass 148 155 self._closed = True 149 156 150 157 class ContentFile(File):