From: zhanghailiang <zhang.zhanghailiang@huawei.com>
To: Michael Tokarev <mjt@tls.msk.ru>
Cc: qemu-trivial@nongnu.org, luonengjun@huawei.com,
qemu-devel@nongnu.org, peter.huangpeng@huawei.com
Subject: Re: [Qemu-trivial] [PATCH v8] slirp/misc: Use the GLib memory allocation APIs
Date: Thu, 21 Aug 2014 08:42:51 +0800 [thread overview]
Message-ID: <53F5408B.3080908@huawei.com> (raw)
In-Reply-To: <53F4B8DE.4050508@msgid.tls.msk.ru>
On 2014/8/20 23:03, Michael Tokarev wrote:
> 20.08.2014 18:57, Michael Tokarev пишет:
>> 19.08.2014 12:30, zhanghailiang wrote:
>>> Here we don't check the return value of malloc() which may fail.
>>> Use the g_new() instead, which will abort the program when
>>> there is not enough memory.
>>>
>>> Also, use g_strdup instead of strdup and remove the unnecessary
>>> strdup function.
>>
>> I also will remove the HAVE_STRDUP define from slirp_config.h --
>> it is no longer needed there.
>>
>> Applied to -trivial (with the above addition), thank you!
>
> ..And with removal of the corresponding #ifdef HAVE_STRDUP from slirp/misc.h.
>
> /mjt
>
>
OK! Thanks.
zhanghailiang
WARNING: multiple messages have this Message-ID (diff)
From: zhanghailiang <zhang.zhanghailiang@huawei.com>
To: Michael Tokarev <mjt@tls.msk.ru>
Cc: qemu-trivial@nongnu.org, luonengjun@huawei.com,
qemu-devel@nongnu.org, peter.huangpeng@huawei.com
Subject: Re: [Qemu-devel] [PATCH v8] slirp/misc: Use the GLib memory allocation APIs
Date: Thu, 21 Aug 2014 08:42:51 +0800 [thread overview]
Message-ID: <53F5408B.3080908@huawei.com> (raw)
In-Reply-To: <53F4B8DE.4050508@msgid.tls.msk.ru>
On 2014/8/20 23:03, Michael Tokarev wrote:
> 20.08.2014 18:57, Michael Tokarev пишет:
>> 19.08.2014 12:30, zhanghailiang wrote:
>>> Here we don't check the return value of malloc() which may fail.
>>> Use the g_new() instead, which will abort the program when
>>> there is not enough memory.
>>>
>>> Also, use g_strdup instead of strdup and remove the unnecessary
>>> strdup function.
>>
>> I also will remove the HAVE_STRDUP define from slirp_config.h --
>> it is no longer needed there.
>>
>> Applied to -trivial (with the above addition), thank you!
>
> ..And with removal of the corresponding #ifdef HAVE_STRDUP from slirp/misc.h.
>
> /mjt
>
>
OK! Thanks.
zhanghailiang
next prev parent reply other threads:[~2014-08-21 0:43 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-19 8:30 [Qemu-trivial] [PATCH v8] slirp/misc: Use the GLib memory allocation APIs zhanghailiang
2014-08-19 8:30 ` [Qemu-devel] " zhanghailiang
2014-08-20 13:23 ` [Qemu-trivial] " Benoît Canet
2014-08-20 13:23 ` Benoît Canet
2014-08-20 14:57 ` [Qemu-trivial] " Michael Tokarev
2014-08-20 14:57 ` [Qemu-devel] " Michael Tokarev
2014-08-20 15:03 ` [Qemu-trivial] " Michael Tokarev
2014-08-20 15:03 ` [Qemu-devel] " Michael Tokarev
2014-08-21 0:42 ` zhanghailiang [this message]
2014-08-21 0:42 ` zhanghailiang
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=53F5408B.3080908@huawei.com \
--to=zhang.zhanghailiang@huawei.com \
--cc=luonengjun@huawei.com \
--cc=mjt@tls.msk.ru \
--cc=peter.huangpeng@huawei.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@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 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.