From bb83b16a3c5ceb112589613f09a0c3af195f8fc9 Mon Sep 17 00:00:00 2001 From: Guanghua Zhang Date: Mon, 12 Aug 2019 09:04:35 +0800 Subject: svm: fix svmtool and svmdbtool segment fault. Type: fix Ticket: VPP-1741 Signed-off-by: Guanghua Zhang Change-Id: Ifd3abaa5ec912378dbc7b73c4863aad26777dd7e (cherry picked from commit 60f16c22b44625d517830b4266a225d3abaccefc) --- src/svm/svmdbtool.c | 2 ++ src/svm/svmtool.c | 2 ++ 2 files changed, 4 insertions(+) (limited to 'src/svm') diff --git a/src/svm/svmdbtool.c b/src/svm/svmdbtool.c index d50ca7be95c..ca8201bd22b 100644 --- a/src/svm/svmdbtool.c +++ b/src/svm/svmdbtool.c @@ -378,6 +378,8 @@ main (int argc, char **argv) struct group _grp, *grp; char *s, buf[128]; + clib_mem_init_thread_safe (0, 128 << 20); + svmdbtool_main.uid = geteuid (); svmdbtool_main.gid = getegid (); diff --git a/src/svm/svmtool.c b/src/svm/svmtool.c index 6d1a2b1da49..643b484bdf5 100644 --- a/src/svm/svmtool.c +++ b/src/svm/svmtool.c @@ -458,6 +458,8 @@ main (int argc, char **argv) char *chroot_path = 0; u8 *chroot_u8; + clib_mem_init_thread_safe (0, 128 << 20); + unformat_init_command_line (&input, argv); while (unformat_check_input (&input) != UNFORMAT_END_OF_INPUT) -- cgit 1.2.3-korg