Skip to content
Snippets Groups Projects
Commit 996dd9c1 authored by Gerardo Tauriello's avatar Gerardo Tauriello
Browse files

Fix indentation

parent d257c616
Branches
Tags
No related merge requests found
...@@ -268,15 +268,14 @@ void export_Scene() ...@@ -268,15 +268,14 @@ void export_Scene()
.add_property("hemi_params",scene_get_hemi_p,scene_set_hemi_p) .add_property("hemi_params",scene_get_hemi_p,scene_set_hemi_p)
; ;
// we need to make sure there are no pending references to Python objects
// tied to the scene singleton. The destructor of
// scene may be called after Python is shutdown which results
// in a segfault.
scope().attr("__dict__")["atexit"]=handle<>(PyImport_ImportModule("atexit"));
// we need to make sure there are no pending references to Python objects def("_clear_scene", &clear_scene);
// tied to the scene singleton. The destructor of object r=scope().attr("_clear_scene");
// scene may be called after Python is shutdown which results scope().attr("atexit").attr("register")(r);
// in a segfault.
scope().attr("__dict__")["atexit"]=handle<>(PyImport_ImportModule("atexit"));
def("_clear_scene", &clear_scene);
object r=scope().attr("_clear_scene");
scope().attr("atexit").attr("register")(r);
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment