[Qemu-devel] [Qemu-trivial] [PATCH v5] util: Use g_malloc/g_free in envlist.c

2017-03-20 Thread Saurav Sachidanand
g_free in bsd-user/main.c and linux-user/main.c. Update comments to reflect change in semantics. Signed-off-by: Saurav Sachidanand --- bsd-user/main.c | 14 -- linux-user/main.c | 9 +++-- util/envlist.c| 47 +++ 3 files changed

Re: [Qemu-devel] [Qemu-trivial] [PATCH v4] util: Use g_malloc/g_free in envlist.c

2017-03-20 Thread Saurav Sachidanand
On Mon, Mar 20, 2017 at 5:32 PM, Saurav Sachidanand wrote: > Change malloc/strdup/free to g_malloc/g_strdup/g_free in > util/envlist.c. > > Remove NULL checks for pointers returned from g_malloc and g_strdup > as they exit in case of failure. Also, update calls to envlist_create &g

[Qemu-devel] [Qemu-trivial] [PATCH v4] util: Use g_malloc/g_free in envlist.c

2017-03-20 Thread Saurav Sachidanand
Change malloc/strdup/free to g_malloc/g_strdup/g_free in util/envlist.c. Remove NULL checks for pointers returned from g_malloc and g_strdup as they exit in case of failure. Also, update calls to envlist_create to reflect this. Free array and array contents returned by envlist_to_environ using g_

[Qemu-devel] [Qemu-trivial] [PATCH v3] util: Use g_malloc/g_free in envlist.c

2017-03-19 Thread Saurav Sachidanand
g_free in bsd-user/main.c and linux-user/main.c. Update comments to reflect change in semantics. Signed-off-by: Saurav Sachidanand --- bsd-user/main.c | 14 -- linux-user/main.c | 9 +++-- util/envlist.c| 47 +++ 3 files changed

[Qemu-devel] [Qemu-trivial] [PATCH v2] util: Use g_malloc/g_free in envlist.c

2017-03-04 Thread Saurav Sachidanand
ron using g_free. Update comments to reflect change in semantics. Refactor nearby code to make scripts/checkpatch.pl happy. Signed-off-by: Saurav Sachidanand --- bsd-user/main.c | 12 +++- linux-user/main.c | 7 ++- util/envlist.c| 34 +++--- 3 fi

[Qemu-devel] [Qemu-trivial] [PATCH] util: Use g_malloc/g_free in envlist.c

2017-03-04 Thread Saurav Sachidanand
ron using g_free. Update comments to reflect change in semantics. Signed-off-by: Saurav Sachidanand --- bsd-user/main.c | 12 +++- linux-user/main.c | 7 ++- util/envlist.c| 31 +-- 3 files changed, 18 insertions(+), 32 deletions(-) diff --git a/