On Thu, Mar 10, 2016 at 09:54:41AM +0800, Fam Zheng wrote:
> On Wed, 03/09 14:10, Peter Xu wrote:
> > +wchar_t *wstr = g_malloc(sizeof(wchar_t) * len);
>
> I think it is better to use g_new() in this case.
Okay. Will re-send this one.
Thanks.
Peter
On Wed, 03/09 14:10, Peter Xu wrote:
> Use heap instead of stack.
>
> Signed-off-by: Peter Xu
> ---
> hw/usb/dev-mtp.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c
> index 7391783..cf63fd0 100644
> --- a/hw/usb/dev-mtp.c
> +++ b
Use heap instead of stack.
Signed-off-by: Peter Xu
---
hw/usb/dev-mtp.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c
index 7391783..cf63fd0 100644
--- a/hw/usb/dev-mtp.c
+++ b/hw/usb/dev-mtp.c
@@ -718,7 +718,7 @@ static void usb_mtp_a