Merge pull request #3450 from opensourcerouting/staticd-sa-warnings

staticd: fix static analysis warnings
This commit is contained in:
Donald Sharp 2018-12-07 15:58:22 -05:00 committed by GitHub
commit b291ac44bc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1211,7 +1211,7 @@ DEFPY(ipv6_route_address_interface,
{ {
struct static_vrf *svrf; struct static_vrf *svrf;
struct static_vrf *nh_svrf; struct static_vrf *nh_svrf;
const char *flag; const char *flag = NULL;
if (table_str && vrf && !vrf_is_mapped_on_netns(vrf_lookup_by_name(vrf))) { if (table_str && vrf && !vrf_is_mapped_on_netns(vrf_lookup_by_name(vrf))) {
vty_out(vty, vty_out(vty,
@ -1280,7 +1280,7 @@ DEFPY(ipv6_route_address_interface_vrf,
VTY_DECLVAR_CONTEXT(vrf, vrf); VTY_DECLVAR_CONTEXT(vrf, vrf);
struct static_vrf *svrf = vrf->info; struct static_vrf *svrf = vrf->info;
struct static_vrf *nh_svrf; struct static_vrf *nh_svrf;
const char *flag; const char *flag = NULL;
if (table_str && !vrf_is_mapped_on_netns(vrf)) { if (table_str && !vrf_is_mapped_on_netns(vrf)) {
vty_out(vty, vty_out(vty,
@ -1341,7 +1341,7 @@ DEFPY(ipv6_route,
{ {
struct static_vrf *svrf; struct static_vrf *svrf;
struct static_vrf *nh_svrf; struct static_vrf *nh_svrf;
const char *flag; const char *flag = NULL;
if (table_str && vrf && !vrf_is_mapped_on_netns(vrf_lookup_by_name(vrf))) { if (table_str && vrf && !vrf_is_mapped_on_netns(vrf_lookup_by_name(vrf))) {
vty_out(vty, vty_out(vty,
@ -1407,7 +1407,7 @@ DEFPY(ipv6_route_vrf,
VTY_DECLVAR_CONTEXT(vrf, vrf); VTY_DECLVAR_CONTEXT(vrf, vrf);
struct static_vrf *svrf = vrf->info; struct static_vrf *svrf = vrf->info;
struct static_vrf *nh_svrf; struct static_vrf *nh_svrf;
const char *flag; const char *flag = NULL;
if (table_str && !vrf_is_mapped_on_netns(vrf)) { if (table_str && !vrf_is_mapped_on_netns(vrf)) {
vty_out(vty, vty_out(vty,