diff --git a/libpod/sqlite_state.go b/libpod/sqlite_state.go index dacb7f041a..add06dd926 100644 --- a/libpod/sqlite_state.go +++ b/libpod/sqlite_state.go @@ -736,8 +736,8 @@ func (s *SQLiteState) AllContainers(loadState bool) ([]*Container, error) { if err := json.Unmarshal([]byte(configJSON), ctr.config); err != nil { return nil, fmt.Errorf("unmarshalling container config: %w", err) } - if err := json.Unmarshal([]byte(stateJSON), ctr.config); err != nil { - return nil, fmt.Errorf("unmarshalling container %s config: %w", ctr.ID(), err) + if err := json.Unmarshal([]byte(stateJSON), ctr.state); err != nil { + return nil, fmt.Errorf("unmarshalling container %s state: %w", ctr.ID(), err) } ctrs = append(ctrs, ctr)