diff mbox

KVM test: Put os.kill in kvm_stat into try block to avoid traceback

Message ID 1269856603-8405-1-git-send-email-yzhou@redhat.com (mailing list archive)
State New, archived
Headers show

Commit Message

Yolkfull Chow March 29, 2010, 9:56 a.m. UTC
None
diff mbox

Patch

diff --git a/client/profilers/kvm_stat/kvm_stat.py b/client/profilers/kvm_stat/kvm_stat.py
index 7568a03..59d6ff6 100644
--- a/client/profilers/kvm_stat/kvm_stat.py
+++ b/client/profilers/kvm_stat/kvm_stat.py
@@ -51,7 +51,10 @@  class kvm_stat(profiler.profiler):
 
         @param test: Autotest test on which this profiler will operate on.
         """
-        os.kill(self.pid, 15)
+        try:
+            os.kill(self.pid, 15)
+        except OSError:
+            pass
 
 
     def report(self, test):