summaryrefslogtreecommitdiff
path: root/lib/librte_eal/common/rte_malloc.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/librte_eal/common/rte_malloc.c')
-rw-r--r--lib/librte_eal/common/rte_malloc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/librte_eal/common/rte_malloc.c b/lib/librte_eal/common/rte_malloc.c
index 9e61dc4..0da5ad5 100644
--- a/lib/librte_eal/common/rte_malloc.c
+++ b/lib/librte_eal/common/rte_malloc.c
@@ -349,8 +349,7 @@ rte_malloc_heap_memory_add(const char *heap_name, void *va_addr, size_t len,
strnlen(heap_name, RTE_HEAP_NAME_MAX_LEN) ==
RTE_HEAP_NAME_MAX_LEN) {
rte_errno = EINVAL;
- ret = -1;
- goto unlock;
+ return -1;
}
rte_rwlock_write_lock(&mcfg->memory_hotplug_lock);