aboutsummaryrefslogtreecommitdiffstats
path: root/src/vpp/api/custom_dump.c
diff options
context:
space:
mode:
authorOle Troan <ot@cisco.com>2019-08-22 09:02:59 +0200
committerAndrew Yourtchenko <ayourtch@gmail.com>2019-08-27 07:51:55 +0000
commit2959d42feb576c0e00c28c4e27658b25f6c783e9 (patch)
tree9b1e3474eb835b4fac2e3edfbcbda9a02a8cc730 /src/vpp/api/custom_dump.c
parent3f1964d2d2847c5307694fe8daea0a7eef1e2733 (diff)
api: use string type for strings in memclnt.api
Explicitly using string type in API allows for autogenerating tools to print strings instead of hex-dumping byte strings. Type: fix Signed-off-by: Ole Troan <ot@cisco.com> Signed-off-by: Klement Sekera <ksekera@cisco.com> Change-Id: I573962d6b34d5d10aab9dc6a5fdf101c9b12a6a6 Signed-off-by: Ole Troan <ot@cisco.com>
Diffstat (limited to 'src/vpp/api/custom_dump.c')
-rw-r--r--src/vpp/api/custom_dump.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/vpp/api/custom_dump.c b/src/vpp/api/custom_dump.c
index 24c37a6872b..403d434050c 100644
--- a/src/vpp/api/custom_dump.c
+++ b/src/vpp/api/custom_dump.c
@@ -2045,8 +2045,10 @@ static void *vl_api_memclnt_create_t_print
(vl_api_memclnt_create_t * mp, void *handle)
{
u8 *s;
+ u8 *name = vl_api_from_api_to_vec (&mp->name);
- s = format (0, "SCRIPT: memclnt_create name %s ", mp->name);
+ s = format (0, "SCRIPT: memclnt_create name %v ", name);
+ vec_free (name);
FINISH;
}
@@ -2055,9 +2057,11 @@ static void *vl_api_sockclnt_create_t_print
(vl_api_sockclnt_create_t * mp, void *handle)
{
u8 *s;
+ u8 *name = vl_api_from_api_to_vec (&mp->name);
- s = format (0, "SCRIPT: sockclnt_create name %s ", mp->name);
+ s = format (0, "SCRIPT: sockclnt_create name %s ", name);
+ vec_free (name);
FINISH;
}