Skip to content

Commit

Permalink
Volume lookup needs to include state to unmarshal into
Browse files Browse the repository at this point in the history
Lookup was written before volume states merged, but merged after,
and CI didn't catch the obvious failure here. Without a valid
state, we try to unmarshall into a null pointer, and 'volume rm'
is completely broken because of it.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
  • Loading branch information
mheon committed Sep 11, 2019
1 parent 093013b commit 5ddfe5d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions libpod/boltdb_state.go
Original file line number Diff line number Diff line change
Expand Up @@ -1749,6 +1749,7 @@ func (s *BoltState) LookupVolume(name string) (*Volume, error) {

volume := new(Volume)
volume.config = new(VolumeConfig)
volume.state = new(VolumeState)

db, err := s.getDBCon()
if err != nil {
Expand Down

0 comments on commit 5ddfe5d

Please sign in to comment.