qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Weil <weil@mail.berlios.de>
To: Anthony Liguori <aliguori@us.ibm.com>
Cc: QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH] Fix prototype of function zfree.
Date: Wed, 27 May 2009 21:24:42 +0200	[thread overview]
Message-ID: <4A1D937A.7000201@mail.berlios.de> (raw)
In-Reply-To: <4A19B448.7010704@mail.berlios.de>

[-- Attachment #1: Type: text/plain, Size: 866 bytes --]

Stefan Weil schrieb:
> Signed-off-by: Stefan Weil <weil@mail.berlios.de>
> ---
>  loader.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/loader.c b/loader.c
> index 5232ee1..9350c54 100644
> --- a/loader.c
> +++ b/loader.c
> @@ -382,7 +382,7 @@ static void *zalloc(void *x, unsigned items,
> unsigned size)
>      return (p);
>  }
>
> -static void zfree(void *x, void *addr, unsigned nb)
> +static void zfree(void *x, void *addr)
>  {
>      qemu_free(addr);
>  }
> @@ -430,7 +430,7 @@ static ssize_t gunzip(void *dst, size_t dstlen,
> uint8_t *src,
>      }
>
>      s.zalloc = zalloc;
> -    s.zfree = (free_func)zfree;
> +    s.zfree = zfree;
>
>      r = inflateInit2(&s, -MAX_WBITS);
>      if (r != Z_OK) {
> --
> 1.5.6.5
>
>
>   

The patch above was whitespace broken.
The appended patch will work.

Regards,

Stefan Weil


[-- Attachment #2: 0004-Fix-prototype-of-function-zfree.patch --]
[-- Type: text/x-diff, Size: 891 bytes --]

>From 850d19151523f20d5d841cd8d3d532b058d4749c Mon Sep 17 00:00:00 2001
From: Stefan Weil <weil@mail.berlios.de>
Date: Sun, 24 May 2009 22:54:06 +0200
Subject: [PATCH] Fix prototype of function zfree.

Signed-off-by: Stefan Weil <weil@mail.berlios.de>
---
 loader.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/loader.c b/loader.c
index 5232ee1..9350c54 100644
--- a/loader.c
+++ b/loader.c
@@ -382,7 +382,7 @@ static void *zalloc(void *x, unsigned items, unsigned size)
     return (p);
 }
 
-static void zfree(void *x, void *addr, unsigned nb)
+static void zfree(void *x, void *addr)
 {
     qemu_free(addr);
 }
@@ -430,7 +430,7 @@ static ssize_t gunzip(void *dst, size_t dstlen, uint8_t *src,
     }
 
     s.zalloc = zalloc;
-    s.zfree = (free_func)zfree;
+    s.zfree = zfree;
 
     r = inflateInit2(&s, -MAX_WBITS);
     if (r != Z_OK) {
-- 
1.5.6.5


      reply	other threads:[~2009-05-27 19:24 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-24 20:55 [Qemu-devel] [PATCH] Fix prototype of function zfree Stefan Weil
2009-05-27 19:24 ` Stefan Weil [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4A1D937A.7000201@mail.berlios.de \
    --to=weil@mail.berlios.de \
    --cc=aliguori@us.ibm.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).