Skip to content

Commit

Permalink
vxlan: check of nil IP in fdb entry
Browse files Browse the repository at this point in the history
Bug fix where nil IP (byte slice) was dereferenced
and caused the goroutine to hang.

Fixes kubernetes#260 and kubernetes#267
  • Loading branch information
Eugene Yakubovich committed Aug 4, 2015
1 parent 63d11a6 commit 0cde4dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/vxlan/vxlan.go
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ func (vb *VXLANBackend) handleInitialSubnetEvents(batch []subnet.Event) error {
}

for j, marker := range fdbEntryMarker {
if !marker {
if !marker && fdbTable[j].IP != nil {
err := vb.dev.DelL2(neigh{IP: ip.FromIP(fdbTable[j].IP), MAC: fdbTable[j].HardwareAddr})
if err != nil {
log.Error("Delete L2 failed: ", err)
Expand Down

0 comments on commit 0cde4dc

Please sign in to comment.