summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--packet/validate_test.go2
-rw-r--r--policy/policy.go4
2 files changed, 3 insertions, 3 deletions
diff --git a/packet/validate_test.go b/packet/validate_test.go
index 46ee3798..d7a22465 100644
--- a/packet/validate_test.go
+++ b/packet/validate_test.go
@@ -171,7 +171,7 @@ func Test_Validate_mandatory_missing(t *testing.T) {
assert.Equal(uint8(BGP_ERROR_UPDATE_MESSAGE_ERROR), e.TypeCode)
assert.Equal(uint8(BGP_ERROR_SUB_MISSING_WELL_KNOWN_ATTRIBUTE), e.SubTypeCode)
missing, _ := binary.Uvarint(e.Data)
- assert.Equal(uint8(1), missing)
+ assert.Equal(uint64(1), missing)
}
func Test_Validate_mandatory_missing_nocheck(t *testing.T) {
diff --git a/policy/policy.go b/policy/policy.go
index bcbc5f82..9dc3632e 100644
--- a/policy/policy.go
+++ b/policy/policy.go
@@ -29,7 +29,7 @@ import (
type RouteType int
const (
- ROUTE_TYPE_NONE = iota
+ ROUTE_TYPE_NONE RouteType = iota
ROUTE_TYPE_ACCEPT
ROUTE_TYPE_REJECT
)
@@ -161,7 +161,7 @@ func (c *PrefixConditions) evaluatePrefix(path table.Path) bool {
for _, cp := range c.PrefixList {
if IpPrefixCalculate(path, cp) {
- log.Debug("prefix matched : ",cp)
+ log.Debug("prefix matched : ", cp)
return true
}
}