feat(shadowsocks): bump from v0.4.0 to v0.5.0-rc1

This commit is contained in:
Quentin McGaw
2023-05-31 14:26:31 +00:00
parent 7399c00508
commit 2ab80771d9
4 changed files with 13 additions and 12 deletions

View File

@@ -22,19 +22,20 @@ func (s *Source) readShadowsocks() (shadowsocks settings.Shadowsocks, err error)
return shadowsocks, nil
}
func (s *Source) readShadowsocksAddress() (address string) {
func (s *Source) readShadowsocksAddress() (address *string) {
key, value := s.getEnvWithRetro("SHADOWSOCKS_LISTENING_ADDRESS",
[]string{"SHADOWSOCKS_PORT"})
if value == nil {
return ""
return nil
}
if key == "SHADOWSOCKS_LISTENING_ADDRESS" {
return *value
return value
}
// Retro-compatibility
return ":" + *value
*value = ":" + *value
return value
}
func (s *Source) readShadowsocksCipher() (cipher string) {