mirror of
https://github.com/osrg/gobgp.git
synced 2024-05-11 05:55:10 +00:00
server: fix GetRib() to handle error properly
fix a bug that GetRib() doesn't return an error even if an error happens.
This commit is contained in:
+1
-1
@@ -1431,7 +1431,7 @@ func (s *BgpServer) GetRib(addr string, family bgp.RouteFamily, prefixes []*tabl
|
||||
return fmt.Errorf("address family: %s not supported", af)
|
||||
}
|
||||
rib, err = tbl.Select(table.TableSelectOption{ID: id, LookupPrefixes: prefixes})
|
||||
return nil
|
||||
return err
|
||||
}, true)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user