Revision 4847a894 proto/bgp/packets.c

View differences:

proto/bgp/packets.c
193 193
  if ((buck = p->withdraw_bucket) && !EMPTY_LIST(buck->prefixes))
194 194
    {
195 195
      DBG("Withdrawn routes:\n");
196
      tmp = bgp_attach_attr(&ea, bgp_linpool, BA_MP_UNREACH_NLRI, remains-8);
196
      tmp = bgp_attach_attr_wa(&ea, bgp_linpool, BA_MP_UNREACH_NLRI, remains-8);
197 197
      *tmp++ = 0;
198 198
      *tmp++ = BGP_AF_IPV6;
199 199
      *tmp++ = 1;
......
218 218
	  size = bgp_encode_attrs(p, w, buck->eattrs, 1024);
219 219
	  w += size;
220 220
	  remains -= size;
221
	  tstart = tmp = bgp_attach_attr(&ea, bgp_linpool, BA_MP_REACH_NLRI, remains-8);
221
	  tstart = tmp = bgp_attach_attr_wa(&ea, bgp_linpool, BA_MP_REACH_NLRI, remains-8);
222 222
	  *tmp++ = 0;
223 223
	  *tmp++ = BGP_AF_IPV6;
224 224
	  *tmp++ = 1;
......
702 702
      /* Create fake NEXT_HOP attribute */
703 703
      if (len < 1 || (*x != 16 && *x != 32) || len < *x + 2)
704 704
	goto bad;
705
      memcpy(bgp_attach_attr(&a0->eattrs, bgp_linpool, BA_NEXT_HOP, 16), x+1, 16);
705
      bgp_attach_attr_ip(&a0->eattrs, bgp_linpool, BA_NEXT_HOP, x[1]);
706 706
      len -= *x + 2;
707 707
      x += *x + 1;
708 708

  

Also available in: Unified diff