Clean up memory handling.
[virt-top.git] / virt-ctrl / virt_ctrl.ml
index 1de68f4..b4a3159 100644 (file)
@@ -29,4 +29,7 @@ let () =
     ~shutdown_domain:Vc_domain_ops.shutdown_domain;
 
   (* Enter the Gtk main loop. *)
-  GMain.main ()
+  GMain.main ();
+
+  (* Useful to catch memory bugs in the ocaml libvirt bindings. *)
+  Gc.compact ()