mirror of
https://github.com/fumiama/WireGold.git
synced 2026-06-05 07:50:24 +08:00
fix(wg): stop signal handling
This commit is contained in:
@@ -56,11 +56,12 @@ func (wg *WG) Run(srcport, destport uint16) {
|
||||
wg.init(srcport, destport)
|
||||
_, err := wg.me.ListenNIC()
|
||||
if err != nil {
|
||||
logrus.Panicln(err)
|
||||
logrus.Warnln(err)
|
||||
}
|
||||
}
|
||||
|
||||
func (wg *WG) Stop() {
|
||||
logrus.Warnln("[wg] stopping...")
|
||||
_ = wg.me.Close()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user