summaryrefslogtreecommitdiffhomepage
path: root/table/destination.go
diff options
context:
space:
mode:
authorISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>2015-08-25 11:29:24 +0900
committerISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>2015-08-25 11:45:23 +0900
commit1d8c71e22b9c974db66ff41cba81ae601ea14dd7 (patch)
tree25e458da32ddc543352452741119aa295dd9a5f5 /table/destination.go
parent64ddb52890451da4c9877f8b3273fb9fe35f878c (diff)
*: better log msg
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
Diffstat (limited to 'table/destination.go')
-rw-r--r--table/destination.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/table/destination.go b/table/destination.go
index 96979a78..290830a4 100644
--- a/table/destination.go
+++ b/table/destination.go
@@ -251,15 +251,16 @@ func (dest *Destination) Calculate() (*Path, string, error) {
//"""
func (dest *Destination) removeWithdrawals() {
+ // If we have no withdrawals, we have nothing to do.
+ if len(dest.withdrawList) == 0 {
+ return
+ }
+
log.WithFields(log.Fields{
"Topic": "Table",
"Key": dest.GetNlri().String(),
"Length": len(dest.withdrawList),
}).Debug("Removing withdrawals")
- // If we have no withdrawals, we have nothing to do.
- if len(dest.withdrawList) == 0 {
- return
- }
// If we have some withdrawals and no know-paths, it means it is safe to
// delete these withdraws.