aboutsummaryrefslogtreecommitdiffstats
path: root/c_parse.go
diff options
context:
space:
mode:
authorJoe <rbo@gmx.us>2023-12-26 20:20:20 +0100
committerJoe <rbo@gmx.us>2023-12-26 20:20:20 +0100
commitfbe50ac4c3ed53f55bfdafaf793eab5efc30d5d3 (patch)
tree884f04c0ca73a2f165a0264bf5062b433ccf7a1a /c_parse.go
parentgood (diff)
downloadhardflip-fbe50ac4c3ed53f55bfdafaf793eab5efc30d5d3.tar.gz
hardflip-fbe50ac4c3ed53f55bfdafaf793eab5efc30d5d3.tar.bz2
hardflip-fbe50ac4c3ed53f55bfdafaf793eab5efc30d5d3.tar.xz
hardflip-fbe50ac4c3ed53f55bfdafaf793eab5efc30d5d3.tar.zst
hardflip-fbe50ac4c3ed53f55bfdafaf793eab5efc30d5d3.zip
fine for now
Diffstat (limited to '')
-rw-r--r--c_parse.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/c_parse.go b/c_parse.go
index d2f1580..407809b 100644
--- a/c_parse.go
+++ b/c_parse.go
@@ -49,6 +49,7 @@ package main
import (
"os"
+
"gopkg.in/yaml.v3"
)
@@ -68,7 +69,7 @@ func c_read_yaml_file(file string) *HostNode {
if len(host.Host) == 0 {
return nil
}
- if host.Type == 0 {
+ if host.Protocol == 0 {
if host.Port == 0 {
host.Port = 22
}
@@ -83,7 +84,7 @@ func c_read_yaml_file(file string) *HostNode {
host.JumpUser = "root"
}
}
- } else if host.Type == 1 {
+ } else if host.Protocol == 1 {
if len(host.User) == 0 {
host.User = "Administrator"
}
@@ -96,7 +97,7 @@ func c_read_yaml_file(file string) *HostNode {
if host.Height == 0 {
host.Height = 1200
}
- } else if host.Type > 1 {
+ } else if host.Protocol > 1 {
return nil
}
if host.Quality > 2 {