mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-11-24 02:59:16 +08:00
fix: 解决中文插件下 ufw 防火墙获取端口列表失败的问题 (#746)
This commit is contained in:
parent
549ccbe6a0
commit
5222388ba1
@ -75,7 +75,7 @@ func (f *Ufw) ListPort() ([]FireInfo, error) {
|
||||
var datas []FireInfo
|
||||
isStart := false
|
||||
for _, line := range portInfos {
|
||||
if strings.HasPrefix(line, "--") {
|
||||
if strings.HasPrefix(line, "-") {
|
||||
isStart = true
|
||||
continue
|
||||
}
|
||||
@ -100,7 +100,7 @@ func (f *Ufw) ListAddress() ([]FireInfo, error) {
|
||||
var datas []FireInfo
|
||||
isStart := false
|
||||
for _, line := range portInfos {
|
||||
if strings.HasPrefix(line, "--") {
|
||||
if strings.HasPrefix(line, "-") {
|
||||
isStart = true
|
||||
continue
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user