Skip to content

Commit f0f6472

Browse files
authored
internal/libhive: fix assignment to entry in nil map bug (#660)
1 parent 53be3f7 commit f0f6472

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

internal/libhive/api.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,10 @@ func (api *simAPI) startClient(w http.ResponseWriter, r *http.Request) {
228228
}
229229
}
230230
// Set default client loglevel to sim loglevel.
231+
if env == nil {
232+
env = make(map[string]string)
233+
}
234+
231235
if env["HIVE_LOGLEVEL"] == "" {
232236
env["HIVE_LOGLEVEL"] = strconv.Itoa(api.env.SimLogLevel)
233237
}

0 commit comments

Comments
 (0)