提交 a0be3303 编写于 作者: Y Yuval Kohavi 提交者: Derek Parker

check that t.conf is not nil in loadConfig

上级 8ce88095
......@@ -247,10 +247,10 @@ func (t *Term) handleExit() (int, error) {
func (t *Term) loadConfig() api.LoadConfig {
r := api.LoadConfig{true, 1, 64, 64, -1}
if t.conf.MaxStringLen != nil {
if t.conf != nil && t.conf.MaxStringLen != nil {
r.MaxStringLen = *t.conf.MaxStringLen
}
if t.conf.MaxArrayValues != nil {
if t.conf != nil && t.conf.MaxArrayValues != nil {
r.MaxArrayValues = *t.conf.MaxArrayValues
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册