fix crash caused by free of uninitialized pointer
Merge pull request #223 from maep--/master

fix crash caused by free of uninitialized pointer