Commit e5578b78 authored by Juliusz Chroboczek's avatar Juliusz Chroboczek

Fix computation of channels_size.

parent c40de851
......@@ -775,9 +775,12 @@ really_send_update(struct network *net,
int add_metric, v4, real_plen, omit = 0;
const unsigned char *real_prefix;
unsigned short flags = 0;
int channels_size =
diversity_kind == DIVERSITY_CHANNEL && channels_len >= 0 ?
channels_len + 2 : 0;
int channels_size;
if(diversity_kind != DIVERSITY_CHANNEL)
channels_len = -1;
channels_size = channels_len >= 0 ? channels_len + 2 : 0;
if(!net_up(net))
return;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment