Fixed ResourceWarning in python 3.2+

This commit is contained in:
Michael Lazar
2015-07-11 00:19:26 -07:00
parent 3c8b563992
commit 8eee962c6b

View File

@@ -130,6 +130,9 @@ def main():
print('Error: could not open file with program "{}", '
'try setting RTV_EDITOR'.format(e.name))
except KeyboardInterrupt:
return
pass
finally:
# Ensure sockets are closed to prevent a ResourceWarning
reddit.handler.http.close()
sys.exit(main())