Skip to content

Commit

Permalink
Merge branch 'er888kh:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
hiddify-com authored Aug 29, 2023
2 parents 6b7902e + 63aa63d commit 285fe34
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,9 @@ func parseHostKeyFile(keyFile string) (ssh.Signer, error) {
func extractNumbers(input string) ([]uint32, error) {
elements := strings.Split(input, ",")
numbers := make([]uint32, 0)
if len(input) == 0 {
return numbers, nil
}

for _, element := range elements {
num, err := strconv.ParseUint(strings.TrimSpace(element), 10, 30) // limit to 30 bits just to be on the safe side
Expand Down

0 comments on commit 285fe34

Please sign in to comment.