summaryrefslogtreecommitdiff
path: root/py/python/Ice.py
diff options
context:
space:
mode:
Diffstat (limited to 'py/python/Ice.py')
-rw-r--r--py/python/Ice.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/py/python/Ice.py b/py/python/Ice.py
index 85752e7a535..5790c64cd8a 100644
--- a/py/python/Ice.py
+++ b/py/python/Ice.py
@@ -53,6 +53,12 @@ if _dlopenflags >= 0:
sys.setdlopenflags(_dlopenflags)
#
+# Give the extension an opportunity to clean up before a graceful exit.
+#
+import atexit
+atexit.register(IcePy.cleanup)
+
+#
# Add some symbols to the Ice module.
#
ObjectPrx = IcePy.ObjectPrx