mirror of
https://github.com/SagerNet/sing-tun.git
synced 2025-04-03 03:47:39 +03:00
auto-redirect: Cleanup before start
This commit is contained in:
parent
086271ef29
commit
9cf07a2b47
1 changed files with 2 additions and 0 deletions
|
@ -134,8 +134,10 @@ func (r *autoRedirect) Start() error {
|
|||
startAt := time.Now()
|
||||
var err error
|
||||
if r.useNFTables {
|
||||
r.cleanupNFTables()
|
||||
err = r.setupNFTables()
|
||||
} else {
|
||||
r.cleanupIPTables()
|
||||
err = r.setupIPTables()
|
||||
}
|
||||
if err != nil {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue