5
0
mirror of https://github.com/cwinfo/yggdrasil-go.git synced 2024-11-10 02:50:27 +00:00

Merge pull request #364 from neilalexander/fix363

Fix getTunTap
This commit is contained in:
Neil Alexander 2019-03-05 17:46:08 +00:00 committed by GitHub
commit fbc0b866fc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -173,9 +173,10 @@ func (a *admin) init(c *Core) {
})
a.addHandler("getTunTap", []string{}, func(in admin_info) (r admin_info, e error) {
defer func() {
recover()
r = admin_info{"none": admin_info{}}
e = nil
if err := recover(); err != nil {
r = admin_info{"none": admin_info{}}
e = nil
}
}()
return admin_info{