summaryrefslogtreecommitdiff
path: root/nest/rt-show.c
diff options
context:
space:
mode:
authorMaria Matejka <mq@ucw.cz>2022-09-01 14:21:56 +0200
committerMaria Matejka <mq@ucw.cz>2022-09-01 17:44:46 +0200
commit397fec4741b40f61d06a467b4110aad7e996485c (patch)
tree4bd33355175e42df9e3b7dee5517c19d4d6e337d /nest/rt-show.c
parent34912b029b161cbbed44057dfa913669ccb087eb (diff)
Default tables are not created unless actually used.
This allows for setting default table values at the beginning of config file before "master4" and "master6" tables are initialized.
Diffstat (limited to 'nest/rt-show.c')
-rw-r--r--nest/rt-show.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/nest/rt-show.c b/nest/rt-show.c
index 17400029..5d7723cf 100644
--- a/nest/rt-show.c
+++ b/nest/rt-show.c
@@ -400,8 +400,8 @@ rt_show_get_default_tables(struct rt_show_data *d)
}
for (int i=1; i<NET_MAX; i++)
- if (config->def_tables[i] && config->def_tables[i]->table)
- rt_show_add_table(d, config->def_tables[i]->table);
+ if (config->def_tables[i] && config->def_tables[i]->table && config->def_tables[i]->table->table)
+ rt_show_add_table(d, config->def_tables[i]->table->table);
}
static inline void