From patchwork Tue Jan 13 19:04:51 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin Ian King X-Patchwork-Id: 428618 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) by ozlabs.org (Postfix) with ESMTP id 6C55B1401EB; Wed, 14 Jan 2015 06:08:28 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from ) id 1YB6pH-0002Lq-Bg; Tue, 13 Jan 2015 19:08:27 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from ) id 1YB6nB-0001va-Sr for fwts-devel@lists.ubuntu.com; Tue, 13 Jan 2015 19:06:17 +0000 Received: from cpc3-craw6-2-0-cust180.croy.cable.virginm.net ([77.100.248.181] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1YB6nB-0004Hl-Pq for fwts-devel@lists.ubuntu.com; Tue, 13 Jan 2015 19:06:17 +0000 From: Colin King To: fwts-devel@lists.ubuntu.com Subject: [PATCH 32/46] lib: fwts_gpe: reduce scope of variables Date: Tue, 13 Jan 2015 19:04:51 +0000 Message-Id: <1421175905-17035-33-git-send-email-colin.king@canonical.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1421175905-17035-1-git-send-email-colin.king@canonical.com> References: <1421175905-17035-1-git-send-email-colin.king@canonical.com> X-BeenThere: fwts-devel@lists.ubuntu.com X-Mailman-Version: 2.1.14 Precedence: list List-Id: Firmware Test Suite Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: fwts-devel-bounces@lists.ubuntu.com Sender: fwts-devel-bounces@lists.ubuntu.com From: Colin Ian King cppcheck is picking up some minor style issues which can be easily fixed: [src/lib/src/fwts_gpe.c:35]: (style) The scope of the variable 'i' can be reduced. Signed-off-by: Colin Ian King Acked-by: Ivan Hu Acked-by: Alex Hung --- src/lib/src/fwts_gpe.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lib/src/fwts_gpe.c b/src/lib/src/fwts_gpe.c index a78c0d8..6ef759f 100644 --- a/src/lib/src/fwts_gpe.c +++ b/src/lib/src/fwts_gpe.c @@ -32,10 +32,10 @@ */ void fwts_gpe_free(fwts_gpe *gpe, const int count) { - int i; - if (gpe) { - for (i=0;i