We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 6b8fc2d + 098a3aa commit ef2228dCopy full SHA for ef2228d
go-controller/pkg/node/gateway_udn.go
@@ -162,7 +162,9 @@ func (udng *UserDefinedNetworkGateway) delMarkChain() error {
162
chain := &knftables.Chain{
163
Name: GetUDNMarkChain(fmt.Sprintf("0x%x", udng.pktMark)),
164
}
165
- tx.Flush(chain)
+ // Delete would return an error if we tried to delete a chain that didn't exist, so
166
+ // we do an Add first (which is a no-op if the chain already exists) and then Delete.
167
+ tx.Add(chain)
168
tx.Delete(chain)
169
return nft.Run(context.TODO(), tx)
170
0 commit comments