Skip processing Advert which carries no events

This commit is contained in:
Milos Gajdos 2019-09-13 20:46:14 +01:00
parent ef86c9625b
commit ccb6778f7f
No known key found for this signature in database
GPG Key ID: 8B31058CC55DFD4F

View File

@ -585,6 +585,11 @@ func (n *network) processCtrlChan(client transport.Client, listener tunnel.Liste
}
events = append(events, e)
}
// if no events are eligible for processing continue
if len(events) == 0 {
log.Debugf("Network no events to be processed by router: %s", n.options.Id)
continue
}
// create an advert and process it
advert := &router.Advert{
Id: pbRtrAdvert.Id,