mirror of
https://github.com/osrg/gobgp.git
synced 2024-05-11 05:55:10 +00:00
server: use pointer
This commit is contained in:
+2
-2
@@ -320,7 +320,7 @@ func (peer *Peer) setDistributePolicy(policyMap map[string]*policy.Policy) {
|
||||
|
||||
}
|
||||
|
||||
func (peer *Peer) applyDistributePolicies(original table.Path) (bool, table.Path) {
|
||||
func (peer *Peer) applyDistributePolicies(original *table.Path) (bool, *table.Path) {
|
||||
policies := peer.distPolicies
|
||||
var d Direction = POLICY_DIRECTION_DISTRIBUTE
|
||||
|
||||
@@ -417,7 +417,7 @@ func (loc *LocalRib) applyPolicies(d Direction, original *table.Path) (bool, *ta
|
||||
return applyPolicy("Loc", loc.OwnerName(), d, policies, original)
|
||||
}
|
||||
|
||||
func applyPolicy(component, owner string, d Direction, policies []*policy.Policy, original table.Path) (bool, table.Path) {
|
||||
func applyPolicy(component, owner string, d Direction, policies []*policy.Policy, original *table.Path) (bool, *table.Path) {
|
||||
var applied bool = true
|
||||
for _, pol := range policies {
|
||||
if result, action, newpath := pol.Apply(original); result {
|
||||
|
||||
Reference in New Issue
Block a user