From patchwork Thu Aug 25 07:23:55 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frediano Ziglio X-Patchwork-Id: 111482 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [140.186.70.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 3352CB6F69 for ; Thu, 25 Aug 2011 17:23:46 +1000 (EST) Received: from localhost ([::1]:42103 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QwUHv-0002Xb-Gl for incoming@patchwork.ozlabs.org; Thu, 25 Aug 2011 03:23:43 -0400 Received: from eggs.gnu.org ([140.186.70.92]:60907) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QwUHq-0002Wd-KL for qemu-devel@nongnu.org; Thu, 25 Aug 2011 03:23:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QwUHp-0003tO-H8 for qemu-devel@nongnu.org; Thu, 25 Aug 2011 03:23:38 -0400 Received: from mail-fx0-f45.google.com ([209.85.161.45]:56314) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QwUHp-0003tK-BC for qemu-devel@nongnu.org; Thu, 25 Aug 2011 03:23:37 -0400 Received: by fxbb27 with SMTP id b27so1749007fxb.4 for ; Thu, 25 Aug 2011 00:23:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; bh=Ds4qSgeF1PqLFDRyV75JY7X/NjdOG7CSoledp7XCI0U=; b=Sw/oeqRaLd1WqskYaelbZODTF6ln8KY/ZXlieDUUu56GneosXM+XEKJU6Kp5YkqPOl fgrjuHUNA5RTQHHBe394KwXvcwyaHKY+BRO5/3wWIOPsEc3mdk3FmqGfUYrELAloUP4k yUPNdzScCtUw1R5c/K6QtpFbRNMchHGmUTVAM= Received: by 10.223.53.205 with SMTP id n13mr8777747fag.15.1314257016460; Thu, 25 Aug 2011 00:23:36 -0700 (PDT) Received: from obol602.omnitel.it ([87.236.194.158]) by mx.google.com with ESMTPS id c4sm64596fac.35.2011.08.25.00.23.31 (version=SSLv3 cipher=OTHER); Thu, 25 Aug 2011 00:23:35 -0700 (PDT) From: Frediano Ziglio To: kwolf@redhat.com Date: Thu, 25 Aug 2011 09:23:55 +0200 Message-Id: <1314257035-7328-1-git-send-email-freddy77@gmail.com> X-Mailer: git-send-email 1.7.1 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.161.45 Cc: qemu-devel@nongnu.org, Frediano Ziglio Subject: [Qemu-devel] [PATCH] qcow2: use always stderr for debugging X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org let all DEBUG_ALLOC2 printf goes to stderr Signed-off-by: Frediano Ziglio --- block/qcow2-cluster.c | 2 +- block/qcow2-refcount.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index 9269dda..9034840 100644 --- a/block/qcow2-cluster.c +++ b/block/qcow2-cluster.c @@ -53,7 +53,7 @@ int qcow2_grow_l1_table(BlockDriverState *bs, int min_size, bool exact_size) } #ifdef DEBUG_ALLOC2 - printf("grow l1_table from %d to %d\n", s->l1_size, new_l1_size); + fprintf(stderr, "grow l1_table from %d to %d\n", s->l1_size, new_l1_size); #endif new_l1_size2 = sizeof(uint64_t) * new_l1_size; diff --git a/block/qcow2-refcount.c b/block/qcow2-refcount.c index 2a915be..fbf28da 100644 --- a/block/qcow2-refcount.c +++ b/block/qcow2-refcount.c @@ -422,7 +422,7 @@ static int QEMU_WARN_UNUSED_RESULT update_refcount(BlockDriverState *bs, int ret; #ifdef DEBUG_ALLOC2 - printf("update_refcount: offset=%" PRId64 " size=%" PRId64 " addend=%d\n", + fprintf(stderr, "update_refcount: offset=%" PRId64 " size=%" PRId64 " addend=%d\n", offset, length, addend); #endif if (length < 0) { @@ -556,7 +556,7 @@ retry: } } #ifdef DEBUG_ALLOC2 - printf("alloc_clusters: size=%" PRId64 " -> %" PRId64 "\n", + fprintf(stderr, "alloc_clusters: size=%" PRId64 " -> %" PRId64 "\n", size, (s->free_cluster_index - nb_clusters) << s->cluster_bits); #endif