Skip to content

Commit 96007a2

Browse files
authored
Merge pull request #2513 from pqarmitage/updates
vrrp: fix segfault when instance has no interface configured
2 parents 889eb4c + 2e2961d commit 96007a2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

keepalived/vrrp/vrrp_data.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -685,7 +685,7 @@ dump_vrrp(FILE *fp, const vrrp_t *vrrp)
685685
/* The following should only be specified for VMACs and ipvlans */
686686
if (__test_bit(VRRP_VMAC_GROUP, &vrrp->flags))
687687
conf_write(fp, " Interface group %u", vrrp->vmac_group);
688-
else if (vrrp->ifp->base_ifp->group)
688+
else if (vrrp->ifp && vrrp->ifp->base_ifp->group)
689689
conf_write(fp, " Interface group %u (copied from parent)", vrrp->ifp->base_ifp->group);
690690

691691
if (vrrp->ifp && vrrp->ifp->is_ours) {

0 commit comments

Comments
 (0)