diff options
| author | Adam Hupp <adam@hupp.org> | 2012-09-17 11:06:00 -0700 |
|---|---|---|
| committer | Adam Hupp <adam@hupp.org> | 2012-09-17 11:06:00 -0700 |
| commit | 91cd6d42ee173bbf117c0e395bcd7bd2084ecbaa (patch) | |
| tree | f6aa7d71ebd2209bdabd0a107322f0c1b3a19650 | |
| parent | 6c23fa27c62c1b3dc0da842fb5e06c7d7aecbfe2 (diff) | |
| parent | 4b88db6041301221eafc306f88a535ba62a53356 (diff) | |
| download | python-magic-91cd6d42ee173bbf117c0e395bcd7bd2084ecbaa.tar.gz | |
Merge pull request #19 from edevil/master
Check if 'magic_close' still has a value on __del__()
| -rw-r--r-- | magic.py | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -69,7 +69,7 @@ class Magic: return magic_file(self.cookie, filename) def __del__(self): - if self.cookie: + if self.cookie and magic_close: magic_close(self.cookie) self.cookie = None |
