On 9/18/20 8:12 AM, Alex Bennée wrote:
Li Qiang writes:
Philippe Mathieu-Daudé 于2020年8月19日周三 下午11:07写道:
On 8/19/20 4:43 PM, Li Qiang wrote:
If g_malloc fails, the application will be terminated.
Which we don't want... better to use g_try_malloc() instead?
I don't think so. If g_malloc
Le 18/09/2020 à 14:53, Laurent Vivier a écrit :
> On 19/08/2020 16:43, Li Qiang wrote:
>> If g_malloc fails, the application will be terminated.
>> No need to check the return value of g_malloc.
>>
>> Signed-off-by: Li Qiang
>> ---
>> hw/virtio/vhost-vdpa.c | 7 +--
>> 1 file changed, 1 inser
Li Qiang writes:
> If g_malloc fails, the application will be terminated.
> No need to check the return value of g_malloc.
>
> Signed-off-by: Li Qiang
I think this is fine because a failure to config the dev would just
cause an error_report later and it's extremely unlikely you don't have
eno
Li Qiang writes:
> Philippe Mathieu-Daudé 于2020年8月19日周三 下午11:07写道:
>>
>> On 8/19/20 4:43 PM, Li Qiang wrote:
>> > If g_malloc fails, the application will be terminated.
>>
>> Which we don't want... better to use g_try_malloc() instead?
>
> I don't think so. If g_malloc return NULL it means a c
On 19/08/2020 16:43, Li Qiang wrote:
> If g_malloc fails, the application will be terminated.
> No need to check the return value of g_malloc.
>
> Signed-off-by: Li Qiang
> ---
> hw/virtio/vhost-vdpa.c | 7 +--
> 1 file changed, 1 insertion(+), 6 deletions(-)
>
> diff --git a/hw/virtio/vhos
Philippe Mathieu-Daudé 于2020年8月19日周三 下午11:07写道:
>
> On 8/19/20 4:43 PM, Li Qiang wrote:
> > If g_malloc fails, the application will be terminated.
>
> Which we don't want... better to use g_try_malloc() instead?
I don't think so. If g_malloc return NULL it means a critical
situation I think termi
On 8/19/20 4:43 PM, Li Qiang wrote:
> If g_malloc fails, the application will be terminated.
Which we don't want... better to use g_try_malloc() instead?
> No need to check the return value of g_malloc.
>
> Signed-off-by: Li Qiang
> ---
> hw/virtio/vhost-vdpa.c | 7 +--
> 1 file changed, 1
If g_malloc fails, the application will be terminated.
No need to check the return value of g_malloc.
Signed-off-by: Li Qiang
---
hw/virtio/vhost-vdpa.c | 7 +--
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/hw/virtio/vhost-vdpa.c b/hw/virtio/vhost-vdpa.c
index 4580f3efd8..403