Skip to content

Commit

Permalink
fix 4282
Browse files Browse the repository at this point in the history
  • Loading branch information
jcp19 committed Sep 11, 2024
1 parent 79e7080 commit 76d47df
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions router/dataplane.go
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,11 @@ func (d *DataPlane) AddNeighborIA(ifID uint16, remote addr.IA) error {
// the given ID is already set, this method will return an error. This can only
// be called on a not yet running dataplane.
func (d *DataPlane) AddLinkType(ifID uint16, linkTo topology.LinkType) error {
d.mtx.Lock()
defer d.mtx.Unlock()
if d.IsRunning() {
return modifyExisting
}
if _, exists := d.linkTypes[ifID]; exists {
return serrors.JoinNoStack(alreadySet, nil, "ifID", ifID)
}
Expand Down

0 comments on commit 76d47df

Please sign in to comment.