diff --git a/internal/journal/volumegroupjournal.go b/internal/journal/volumegroupjournal.go index 7d6a2b77e2e2..99ad8dafd1b2 100644 --- a/internal/journal/volumegroupjournal.go +++ b/internal/journal/volumegroupjournal.go @@ -143,7 +143,10 @@ func (vgc *VolumeGroupJournalConfig) Connect( // Destroy frees any resources and invalidates the journal connection. func (vgjc *volumeGroupJournalConnection) Destroy() { - vgjc.connection.Destroy() + if vgjc.connection != nil { + vgjc.connection.Destroy() + vgjc.connection = nil + } } // VolumeGroupData contains the GroupUUID and VolumeGroupAttributes for a