[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v5] common/vm_event: Initialize vm_event lists on domain creation



On 08/29/2017 08:41 PM, Wei Liu wrote:
>>>> -    xfree(d->vm_event);
>>>> +#ifdef CONFIG_HAS_MEM_PAGING
>>>> +    xfree(d->vm_event_paging);
>>>> +#endif
>>>> +    xfree(d->vm_event_monitor);
>>> Why do you unconditionally xfree these vm_event_monitor while you don't
>>> unconditionally allocate them?
>>>
>>> Not that this is strictly a bug but this deviates from the original
>>> behaviour.
>> Isn't xfree NULL safe?
> Yes, it is.

That was my suggestion: since xfree() can handle NULL I thought the
patch would have minimal changes and be easier to review if we omit
unnecessary lines.


Thanks,
Razvan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.