Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754585AbbEOGoB (ORCPT ); Fri, 15 May 2015 02:44:01 -0400 Received: from terminus.zytor.com ([198.137.202.10]:58155 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753999AbbEOGn5 (ORCPT ); Fri, 15 May 2015 02:43:57 -0400 Date: Thu, 14 May 2015 23:43:37 -0700 From: tip-bot for He Kuang Message-ID: Cc: tglx@linutronix.de, a.p.zijlstra@chello.nl, acme@redhat.com, hpa@zytor.com, hekuang@huawei.com, mingo@kernel.org, wangnan0@huawei.com, jolsa@kernel.org, linux-kernel@vger.kernel.org Reply-To: jolsa@kernel.org, linux-kernel@vger.kernel.org, hekuang@huawei.com, mingo@kernel.org, wangnan0@huawei.com, acme@redhat.com, hpa@zytor.com, tglx@linutronix.de, a.p.zijlstra@chello.nl In-Reply-To: <1431347316-30401-2-git-send-email-hekuang@huawei.com> References: <1431347316-30401-2-git-send-email-hekuang@huawei.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf trace: Removed duplicated NULL test Git-Commit-ID: ff8f695c0ec9d73d8a9f92fe634d6476ad74e3a1 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1548 Lines: 43 Commit-ID: ff8f695c0ec9d73d8a9f92fe634d6476ad74e3a1 Gitweb: http://git.kernel.org/tip/ff8f695c0ec9d73d8a9f92fe634d6476ad74e3a1 Author: He Kuang AuthorDate: Mon, 11 May 2015 12:28:36 +0000 Committer: Arnaldo Carvalho de Melo CommitDate: Tue, 12 May 2015 09:59:49 -0300 perf trace: Removed duplicated NULL test No need to test trace.evlist against NULL twice. Signed-off-by: He Kuang Cc: Jiri Olsa Cc: Peter Zijlstra Cc: Wang Nan Link: http://lkml.kernel.org/r/1431347316-30401-2-git-send-email-hekuang@huawei.com Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/builtin-trace.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c index cbfdb95..96a2eba 100644 --- a/tools/perf/builtin-trace.c +++ b/tools/perf/builtin-trace.c @@ -2721,11 +2721,10 @@ int cmd_trace(int argc, const char **argv, const char *prefix __maybe_unused) signal(SIGFPE, sighandler_dump_stack); trace.evlist = perf_evlist__new(); - if (trace.evlist == NULL) - return -ENOMEM; if (trace.evlist == NULL) { pr_err("Not enough memory to run!\n"); + err = -ENOMEM; goto out; } -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/