From patchwork Mon Mar 29 09:56:43 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yolkfull Chow X-Patchwork-Id: 88935 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o2T9v04V005012 for ; Mon, 29 Mar 2010 09:57:00 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754884Ab0C2J4v (ORCPT ); Mon, 29 Mar 2010 05:56:51 -0400 Received: from mx1.redhat.com ([209.132.183.28]:30513 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754846Ab0C2J4u (ORCPT ); Mon, 29 Mar 2010 05:56:50 -0400 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o2T9unJh014986 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 29 Mar 2010 05:56:49 -0400 Received: from localhost.localdomain (dhcp-65-181.nay.redhat.com [10.66.65.181]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o2T9ukhM003996; Mon, 29 Mar 2010 05:56:47 -0400 From: Yolkfull Chow To: autotest@test.kernel.org Cc: kvm@vger.kernel.org, Yolkfull Chow Subject: [PATCH] KVM test: Put os.kill in kvm_stat into try block to avoid traceback Date: Mon, 29 Mar 2010 17:56:43 +0800 Message-Id: <1269856603-8405-1-git-send-email-yzhou@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.18 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Mon, 29 Mar 2010 09:57:00 +0000 (UTC) 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):