Re: [Qemu-devel] [PATCH V26 05/32] QemuOpts: change opt->name|str from (const char *) to (char *)

2014-05-01 Thread Leandro Dorileo
On Tue, Apr 29, 2014 at 05:08:14PM +0800, Chunyan Liu wrote: > qemu_opt_del() already assumes that all QemuOpt instances contain > malloc'd name and value; but it had to cast away const because > opts_start_struct() was doing its own thing and using static storage > instead. By using the correct t

[Qemu-devel] [PATCH V26 05/32] QemuOpts: change opt->name|str from (const char *) to (char *)

2014-04-29 Thread Chunyan Liu
qemu_opt_del() already assumes that all QemuOpt instances contain malloc'd name and value; but it had to cast away const because opts_start_struct() was doing its own thing and using static storage instead. By using the correct type and malloced strings everywhere, the usage of this struct becomes

[Qemu-devel] [PATCH V26 05/32] QemuOpts: change opt->name|str from (const char *) to (char *)

2014-04-29 Thread Chunyan Liu
qemu_opt_del() already assumes that all QemuOpt instances contain malloc'd name and value; but it had to cast away const because opts_start_struct() was doing its own thing and using static storage instead. By using the correct type and malloced strings everywhere, the usage of this struct becomes