From patchwork Wed Jul 24 15:41:10 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yordan Karadzhov X-Patchwork-Id: 11057111 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 7843513A4 for ; Wed, 24 Jul 2019 15:41:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 69D49284A3 for ; Wed, 24 Jul 2019 15:41:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5E48E288AC; Wed, 24 Jul 2019 15:41:23 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 181BB284A3 for ; Wed, 24 Jul 2019 15:41:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727715AbfGXPlW (ORCPT ); Wed, 24 Jul 2019 11:41:22 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:55484 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727035AbfGXPlW (ORCPT ); Wed, 24 Jul 2019 11:41:22 -0400 Received: by mail-wm1-f65.google.com with SMTP id a15so42258676wmj.5 for ; Wed, 24 Jul 2019 08:41:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=85A9C8HeH4Yjsbu/IBi1pXxnaeb0xH9cjbozsUzat8Y=; b=KTRx2ZzYPGa3i4U/J0ksfLla02xi42ORdZ8EEnYALtjwKYoC8g8v5Xk8Yt02bh6g8j 58nEt/C5subEVSRYeuBRAivjJuyo3QMON5wTD8sRnvBVBJk3elXU451TTsPN40iHX1ki Z0+w9dBZxtfhS8Iro2UCyCzZHF6tuQkr6bfrCkyGd30e98YnBCwB0cqwwKiHFm0dDLNg sktOYa3cC4b2w1jcX5RESyvK96EgX2+N2+5d4lz/xxhoWJcPeNqds5/IhiP2Tjv/7W3S v9G++wz/KgNy+IyjqQvQyBDv+CnouGyWLqug+W3lyioX9ulvWH1BL0fwcsaltqbVttNX cagA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=85A9C8HeH4Yjsbu/IBi1pXxnaeb0xH9cjbozsUzat8Y=; b=jj5Fp5D6s9rCKJo5dKo8iiI/Xl1g7iXvfH5kJQgicRGjsOw4/+VI5i4qvO/sUwW/H6 RHEs0jjLIWsD5kOHBXe9UuVtvLCa1A7w+YNqrWWirM+PYCw83EpumQmFOpua5otTRoSq eWDqtEvbazc4N+0kr63Nwtq1e99pdehoKdOPgqbNVotrFiRnPrKmZEl8sPIiCEmX6Xhc Pq9Q41xG2fv6b1O8coX93foKBQKTqnGn2t5lUZ66hFrUPww/NJK+AzC1u1Vn61yat4ek LGMWVTZ+enftImJUIOSX72LdlgRnvwOKPKZU3i7CKNll3ddkJD2M8gBYZ4MehWFSucKh 9loA== X-Gm-Message-State: APjAAAWoEh7W6n3U+MXrVRz2EktOzGa24acEzPovUj7pEJdy9hLP5qOE XQYPEEdqbRC8MnCJZ+hfv2w= X-Google-Smtp-Source: APXvYqzHeEHj7iNGiaZywcc4HdgLIs+fMz3j4oVxyFJksV1Z4cZ/IXLUFIoXJms4XCdqWNXKiqTt3g== X-Received: by 2002:a05:600c:20c1:: with SMTP id y1mr77296419wmm.10.1563982880700; Wed, 24 Jul 2019 08:41:20 -0700 (PDT) Received: from localhost.localdomain ([95.87.223.238]) by smtp.gmail.com with ESMTPSA id f17sm42005546wmf.27.2019.07.24.08.41.20 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Wed, 24 Jul 2019 08:41:20 -0700 (PDT) From: "Yordan Karadzhov (VMware)" To: rostedt@goodmis.org Cc: linux-trace-devel@vger.kernel.org, "Yordan Karadzhov (VMware)" Subject: [PATCH v2] kernel-shark: Disable Capture if trace-cmd can't function Date: Wed, 24 Jul 2019 18:41:10 +0300 Message-Id: <20190724154110.23772-1-y.karadz@gmail.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Sender: linux-trace-devel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-trace-devel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP In the case of an error the "Capture" button of the Record dialog is disabled. Signed-off-by: Yordan Karadzhov (VMware) --- kernel-shark/src/KsCaptureDialog.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kernel-shark/src/KsCaptureDialog.cpp b/kernel-shark/src/KsCaptureDialog.cpp index 2e6e8f9..888ffea 100644 --- a/kernel-shark/src/KsCaptureDialog.cpp +++ b/kernel-shark/src/KsCaptureDialog.cpp @@ -74,6 +74,9 @@ KsCaptureControl::KsCaptureControl(QWidget *parent) _topLayout.addWidget(errorLabel); lamAddLine(); + + /* Disable "Capture" buttons. */ + _captureButton.setDisabled(true); } pluginList.prepend("nop");