summaryrefslogtreecommitdiffstats
path: root/src/plugins/memif/memif_api.c
diff options
context:
space:
mode:
authorDamjan Marion <dmarion@me.com>2023-01-31 20:14:13 +0100
committerDave Wallace <dwallacelf@gmail.com>2023-02-01 14:50:33 +0000
commitab4d9174d890bff4c07b44957a20eacb33c88172 (patch)
treed45c2579c3948a9b1b080cff0dcb09468e1cbebe /src/plugins/memif/memif_api.c
parent4d290c3aa74c7bd346b311940e5feb399464057e (diff)
memif: improve error reporting
Type: improvement Change-Id: I12b120d988347cced3df82810e86dc2fd5cfca80 Signed-off-by: Damjan Marion <dmarion@me.com>
Diffstat (limited to 'src/plugins/memif/memif_api.c')
-rw-r--r--src/plugins/memif/memif_api.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/plugins/memif/memif_api.c b/src/plugins/memif/memif_api.c
index 593306a1ec7..04c2c8daab2 100644
--- a/src/plugins/memif/memif_api.c
+++ b/src/plugins/memif/memif_api.c
@@ -74,7 +74,8 @@ void
memcpy (socket_filename, mp->socket_filename, len);
}
- rv = memif_socket_filename_add_del (is_add, socket_id, socket_filename);
+ rv = vnet_api_error (
+ memif_socket_filename_add_del (is_add, socket_id, socket_filename));
vec_free (socket_filename);
@@ -164,7 +165,7 @@ vl_api_memif_create_t_handler (vl_api_memif_create_t * mp)
args.hw_addr_set = 1;
}
- rv = memif_create_if (vm, &args);
+ rv = vnet_api_error (memif_create_if (vm, &args));
vec_free (args.secret);
@@ -201,7 +202,7 @@ vl_api_memif_delete_t_handler (vl_api_memif_delete_t * mp)
else
{
mif = pool_elt_at_index (mm->interfaces, hi->dev_instance);
- rv = memif_delete_if (vm, mif);
+ rv = vnet_api_error (memif_delete_if (vm, mif));
}
REPLY_MACRO (VL_API_MEMIF_DELETE_REPLY);