Fix crash when closing preferences
Merge pull request #590 from timrae/saveColCrash

Fix crash when closing preferences