mirror of
				https://gitlab.labs.nic.cz/labs/bird.git
				synced 2024-05-11 16:54:54 +00:00 
			
		
		
		
	Moved route preference to eattrs
This commit is contained in:
		| @@ -588,7 +588,7 @@ ospf_get_route_info(rte * rte, byte * buf) | ||||
|   } | ||||
|  | ||||
|   buf += bsprintf(buf, " %s", type); | ||||
|   buf += bsprintf(buf, " (%d/%d", rte->attrs->pref, ea_get_int(rte->attrs->eattrs, &ea_ospf_metric1, LSINFINITY)); | ||||
|   buf += bsprintf(buf, " (%d/%d", rt_get_preference(rte), ea_get_int(rte->attrs->eattrs, &ea_ospf_metric1, LSINFINITY)); | ||||
|   if (rte->attrs->source == RTS_OSPF_EXT2) | ||||
|     buf += bsprintf(buf, "/%d", ea_get_int(rte->attrs->eattrs, &ea_ospf_metric2, LSINFINITY)); | ||||
|   buf += bsprintf(buf, ")"); | ||||
|   | ||||
| @@ -2057,7 +2057,6 @@ again1: | ||||
| 	.scope = SCOPE_UNIVERSE, | ||||
| 	.dest = RTD_UNICAST, | ||||
| 	.nh = *(nf->n.nhs), | ||||
| 	.pref = p->p.main_channel->preference, | ||||
|       }; | ||||
|  | ||||
|       if (reload || ort_changed(nf, &a0)) | ||||
| @@ -2069,11 +2068,14 @@ again1: | ||||
|  | ||||
| 	struct { | ||||
| 	  ea_list l; | ||||
| 	  eattr a[4]; | ||||
| 	  eattr a[5]; | ||||
| 	} eattrs; | ||||
|  | ||||
| 	eattrs.l = (ea_list) {}; | ||||
|  | ||||
| 	eattrs.a[eattrs.l.count++] = | ||||
| 	  EA_LITERAL_EMBEDDED(&ea_gen_preference, 0, p->p.main_channel->preference); | ||||
|  | ||||
| 	eattrs.a[eattrs.l.count++] = | ||||
| 	  EA_LITERAL_EMBEDDED(&ea_ospf_metric1, 0, nf->n.metric1); | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user