mirror of https://github.com/xqemu/xqemu.git
rdma: g_malloc0() can't fail, bury dead error handling
Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Gonglei <arei.gonglei@huawei.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
parent
9834fe02b0
commit
e75bef035a
|
@ -1121,9 +1121,6 @@ static int qemu_rdma_register_and_get_keys(RDMAContext *rdma,
|
||||||
/* allocate memory to store chunk MRs */
|
/* allocate memory to store chunk MRs */
|
||||||
if (!block->pmr) {
|
if (!block->pmr) {
|
||||||
block->pmr = g_malloc0(block->nb_chunks * sizeof(struct ibv_mr *));
|
block->pmr = g_malloc0(block->nb_chunks * sizeof(struct ibv_mr *));
|
||||||
if (!block->pmr) {
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Reference in New Issue