From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Ly57W-000480-4L for qemu-devel@nongnu.org; Sun, 26 Apr 2009 10:14:14 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Ly57R-00046F-IP for qemu-devel@nongnu.org; Sun, 26 Apr 2009 10:14:13 -0400 Received: from [199.232.76.173] (port=42358 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ly57R-00046A-9Y for qemu-devel@nongnu.org; Sun, 26 Apr 2009 10:14:09 -0400 Received: from mx2.redhat.com ([66.187.237.31]:46400) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Ly57Q-00068h-Tg for qemu-devel@nongnu.org; Sun, 26 Apr 2009 10:14:09 -0400 Message-ID: <49F46C2B.9060705@redhat.com> Date: Sun, 26 Apr 2009 17:14:03 +0300 From: Avi Kivity MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] qcow2 corruption: Fix alloc_cluster_link_l2 References: <1239789151-23552-1-git-send-email-kwolf@redhat.com> <20090426132444.GA22238@lst.de> In-Reply-To: <20090426132444.GA22238@lst.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Christoph Hellwig Cc: Kevin Wolf , dlaor@redhat.com, qemu-devel@nongnu.org, gleb@redhat.com Christoph Hellwig wrote: > Maybe it's time to make use of sparse's endianess annotations in qcow2 > to prevent further problems like this one I'd much prefer strong type checking at compile time: typedef struct le32 { uint32_t blah; } le32; static inline le32 cpu_to_le32(uint32_t blah) { ... } static inline uint32_t le32_to_cpu(le32 blah) { ... } -- error compiling committee.c: too many arguments to function