|
@@ -109,6 +109,7 @@ type Server struct {
|
109
|
109
|
operclasses map[string]OperClass
|
110
|
110
|
password []byte
|
111
|
111
|
passwords *passwd.SaltedManager
|
|
112
|
+ recoverFromErrors bool
|
112
|
113
|
registeredChannels map[string]*RegisteredChannel
|
113
|
114
|
registeredChannelsMutex sync.RWMutex
|
114
|
115
|
rehashMutex sync.Mutex
|
|
@@ -1239,21 +1240,23 @@ func (server *Server) applyConfig(config *Config, initial bool) error {
|
1239
|
1240
|
server.name = config.Server.Name
|
1240
|
1241
|
server.nameCasefolded = casefoldedName
|
1241
|
1242
|
}
|
1242
|
|
- server.networkName = config.Network.Name
|
1243
|
1243
|
|
1244
|
1244
|
server.configurableStateMutex.Lock()
|
|
1245
|
+ server.networkName = config.Network.Name
|
1245
|
1246
|
if config.Server.Password != "" {
|
1246
|
1247
|
server.password = config.Server.PasswordBytes()
|
1247
|
1248
|
} else {
|
1248
|
1249
|
server.password = nil
|
1249
|
1250
|
}
|
1250
|
|
- server.configurableStateMutex.Unlock()
|
1251
|
|
-
|
1252
|
1251
|
// apply new WebIRC command restrictions
|
1253
|
1252
|
server.webirc = config.Server.WebIRC
|
1254
|
|
-
|
1255
|
1253
|
// apply new PROXY command restrictions
|
1256
|
1254
|
server.proxyAllowedFrom = config.Server.ProxyAllowedFrom
|
|
1255
|
+ server.recoverFromErrors = true
|
|
1256
|
+ if config.Debug.RecoverFromErrors != nil {
|
|
1257
|
+ server.recoverFromErrors = *config.Debug.RecoverFromErrors
|
|
1258
|
+ }
|
|
1259
|
+ server.configurableStateMutex.Unlock()
|
1257
|
1260
|
|
1258
|
1261
|
err = server.connectionLimiter.ApplyConfig(config.Server.ConnectionLimiter)
|
1259
|
1262
|
if err != nil {
|