summaryrefslogtreecommitdiffstats
path: root/src/vat/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vat/main.c')
-rw-r--r--src/vat/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vat/main.c b/src/vat/main.c
index 893a1022ab7..996fb1ed6a8 100644
--- a/src/vat/main.c
+++ b/src/vat/main.c
@@ -31,7 +31,7 @@ int
connect_to_vpe (char *name)
{
vat_main_t *vam = &vat_main;
- api_main_t *am = &api_main;
+ api_main_t *am = vlibapi_get_main ();
if (vl_client_connect_to_vlib ("/vpe-api", name, 32) < 0)
return -1;
@@ -185,7 +185,7 @@ do_one_file (vat_main_t * vam)
if (vam->client_index_invalid)
{
vat_main_t *vam = &vat_main;
- api_main_t *am = &api_main;
+ api_main_t *am = vlibapi_get_main ();
vam->vl_input_queue = am->shmem_hdr->vl_input_queue;
vam->my_client_index = am->my_client_index;