From patchwork Sun Jul 20 08:26:31 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Klausner X-Patchwork-Id: 4590601 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 13AA09F37C for ; Sun, 20 Jul 2014 08:26:56 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 4BCF42010C for ; Sun, 20 Jul 2014 08:26:55 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 92F6F2010F for ; Sun, 20 Jul 2014 08:26:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id EBD4A6E2F3; Sun, 20 Jul 2014 01:26:53 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from fep26.mx.upcmail.net (fep26.mx.upcmail.net [62.179.121.46]) by gabe.freedesktop.org (Postfix) with ESMTP id 52A246E2ED for ; Sun, 20 Jul 2014 01:26:47 -0700 (PDT) Received: from edge01.upcmail.net ([192.168.13.236]) by viefep26-int.chello.at (InterMail vM.8.01.05.05 201-2260-151-110-20120111) with ESMTP id <20140720082529.QDHJ22047.viefep26-int.chello.at@edge01.upcmail.net>; Sun, 20 Jul 2014 10:25:29 +0200 Received: from yt.nih.at ([213.47.1.69]) by edge01.upcmail.net with edge id UYSh1o00i1VKkul01YShPC; Sun, 20 Jul 2014 10:26:44 +0200 X-SourceIP: 213.47.1.69 Received: by yt.nih.at (Postfix, from userid 1000) id 741382AC0B7; Sun, 20 Jul 2014 10:26:41 +0200 (CEST) From: Thomas Klausner To: dri-devel@lists.freedesktop.org Subject: [PATCH:drm 1/4] intel: Only define variable when it's used. Date: Sun, 20 Jul 2014 10:26:31 +0200 Message-Id: <1405844794-27210-1-git-send-email-wiz@NetBSD.org> X-Mailer: git-send-email 1.9.4 Cc: Thomas Klausner X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Thomas Klausner --- intel/test_decode.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/intel/test_decode.c b/intel/test_decode.c index b710f34..f9127cf 100644 --- a/intel/test_decode.c +++ b/intel/test_decode.c @@ -90,7 +90,10 @@ compare_batch(struct drm_intel_decode *ctx, const char *batch_filename) { FILE *out = NULL; void *ptr, *ref_ptr, *batch_ptr; - size_t size, ref_size, batch_size; +#ifdef HAVE_OPEN_MEMSTREAM + size_t size; +#endif + size_t ref_size, batch_size; const char *ref_suffix = "-ref.txt"; char *ref_filename;