From: "Andreas Färber" <afaerber@suse.de>
To: Stefan Weil <sw@weilnetz.de>
Cc: qemu-trivial <qemu-trivial@nongnu.org>,
Blue Swirl <blauwirbel@gmail.com>,
qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-trivial] [Qemu-devel] [PATCH] target-sparc: Replace free by g_free
Date: Tue, 11 Jun 2013 14:27:46 +0200 [thread overview]
Message-ID: <51B717C2.5050906@suse.de> (raw)
In-Reply-To: <1370896852-12473-1-git-send-email-sw@weilnetz.de>
Am 10.06.2013 22:40, schrieb Stefan Weil:
> The wrong function was reported by cppcheck.
>
> Signed-off-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: Andreas Färber <afaerber@suse.de>
> ---
> target-sparc/cpu.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/target-sparc/cpu.c b/target-sparc/cpu.c
> index 290b580..13bb7bb 100644
> --- a/target-sparc/cpu.c
> +++ b/target-sparc/cpu.c
> @@ -614,7 +614,7 @@ static int cpu_sparc_find_by_name(sparc_def_t *cpu_def, const char *cpu_model)
> return 0;
>
> error:
> - free(s);
> + g_free(s);
> return -1;
> }
>
So s is for the string, and matches occurrence above, fine.
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
WARNING: multiple messages have this Message-ID (diff)
From: "Andreas Färber" <afaerber@suse.de>
To: Stefan Weil <sw@weilnetz.de>
Cc: qemu-trivial <qemu-trivial@nongnu.org>,
Blue Swirl <blauwirbel@gmail.com>,
Michael Tokarev <mjt@tls.msk.ru>,
qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH] target-sparc: Replace free by g_free
Date: Tue, 11 Jun 2013 14:27:46 +0200 [thread overview]
Message-ID: <51B717C2.5050906@suse.de> (raw)
In-Reply-To: <1370896852-12473-1-git-send-email-sw@weilnetz.de>
Am 10.06.2013 22:40, schrieb Stefan Weil:
> The wrong function was reported by cppcheck.
>
> Signed-off-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: Andreas Färber <afaerber@suse.de>
> ---
> target-sparc/cpu.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/target-sparc/cpu.c b/target-sparc/cpu.c
> index 290b580..13bb7bb 100644
> --- a/target-sparc/cpu.c
> +++ b/target-sparc/cpu.c
> @@ -614,7 +614,7 @@ static int cpu_sparc_find_by_name(sparc_def_t *cpu_def, const char *cpu_model)
> return 0;
>
> error:
> - free(s);
> + g_free(s);
> return -1;
> }
>
So s is for the string, and matches occurrence above, fine.
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
next prev parent reply other threads:[~2013-06-11 12:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-10 20:40 [Qemu-trivial] [PATCH] target-sparc: Replace free by g_free Stefan Weil
2013-06-10 20:40 ` [Qemu-devel] " Stefan Weil
2013-06-11 12:13 ` [Qemu-trivial] " Michael Tokarev
2013-06-11 12:13 ` [Qemu-devel] " Michael Tokarev
2013-06-11 12:27 ` Andreas Färber [this message]
2013-06-11 12:27 ` [Qemu-devel] " Andreas Färber
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=51B717C2.5050906@suse.de \
--to=afaerber@suse.de \
--cc=blauwirbel@gmail.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
--cc=sw@weilnetz.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.