mirror of
https://github.com/ergochat/ergo.git
synced 2024-11-10 22:19:31 +01:00
Re-enable MaxLine
This commit is contained in:
parent
3db6c9472b
commit
63fde2d62a
@ -529,8 +529,11 @@ func LoadConfig(filename string) (config *Config, err error) {
|
|||||||
}
|
}
|
||||||
config.Server.WebIRC = newWebIRC
|
config.Server.WebIRC = newWebIRC
|
||||||
// process limits
|
// process limits
|
||||||
if config.Limits.LineLen.Tags < 512 || config.Limits.LineLen.Rest < 512 {
|
if config.Limits.LineLen.Tags < 512 {
|
||||||
return nil, ErrLineLengthsTooSmall
|
config.Limits.LineLen.Tags = 512
|
||||||
|
}
|
||||||
|
if config.Limits.LineLen.Rest < 512 {
|
||||||
|
config.Limits.LineLen.Rest = 512
|
||||||
}
|
}
|
||||||
var newLogConfigs []logger.LoggingConfig
|
var newLogConfigs []logger.LoggingConfig
|
||||||
for _, logConfig := range config.Logging {
|
for _, logConfig := range config.Logging {
|
||||||
|
@ -693,6 +693,13 @@ func (server *Server) applyConfig(config *Config, initial bool) (err error) {
|
|||||||
server.accounts.initVHostRequestQueue()
|
server.accounts.initVHostRequestQueue()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// MaxLine
|
||||||
|
if config.Limits.LineLen.Tags != 512 || config.Limits.LineLen.Rest != 512 {
|
||||||
|
SupportedCapabilities.Enable(caps.MaxLine)
|
||||||
|
value := fmt.Sprintf("%d,%d", config.Limits.LineLen.Tags, config.Limits.LineLen.Rest)
|
||||||
|
CapValues.Set(caps.MaxLine, value)
|
||||||
|
}
|
||||||
|
|
||||||
// STS
|
// STS
|
||||||
stsPreviouslyEnabled := oldConfig != nil && oldConfig.Server.STS.Enabled
|
stsPreviouslyEnabled := oldConfig != nil && oldConfig.Server.STS.Enabled
|
||||||
stsValue := config.Server.STS.Value()
|
stsValue := config.Server.STS.Value()
|
||||||
|
Loading…
Reference in New Issue
Block a user