lib: Utilize smaps in the idl.
[sliver-openvswitch.git] / python / ovs / fatal_signal.py
index f2edc85..e6fe783 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (c) 2010, 2011 Nicira Networks
+# Copyright (c) 2010, 2011 Nicira, Inc.
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
 # limitations under the License.
 
 import atexit
-import logging
 import os
 import signal
 
+import ovs.vlog
+
 _hooks = []
+vlog = ovs.vlog.Vlog("fatal-signal")
 
 
 def add_hook(hook, cancel, run_at_exit):
@@ -67,8 +69,7 @@ def unlink_file_now(file):
     Returns 0 if successful, otherwise a positive errno value."""
     error = _unlink(file)
     if error:
-        logging.warning("could not unlink \"%s\" (%s)"
-                        % (file, os.strerror(error)))
+        vlog.warn("could not unlink \"%s\" (%s)" % (file, os.strerror(error)))
     remove_file_to_unlink(file)
     return error